WP_Customize_Custom_CSS_Setting constructor.
Parameters
$manager
WP_Customize_Managerrequired- Customizer bootstrap instance.
$id
stringrequired- A specific ID of the setting.
Can be a theme mod or option name. $args
arrayoptional- Setting arguments.
Default:
array()
Source
public function __construct( $manager, $id, $args = array() ) {
parent::__construct( $manager, $id, $args );
if ( 'custom_css' !== $this->id_data['base'] ) {
throw new Exception( 'Expected custom_css id_base.' );
}
if ( 1 !== count( $this->id_data['keys'] ) || empty( $this->id_data['keys'][0] ) ) {
throw new Exception( 'Expected single stylesheet key.' );
}
$this->stylesheet = $this->id_data['keys'][0];
}
Changelog
Version | Description |
---|---|
4.7.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.