customize_controls_init
Fires when Customizer controls are initialized, before scripts are enqueued.
Description
do_action( 'customize_controls_init' );
Usage
- To run the hook, copy the example below.
- // run the action
- do_action( 'customize_controls_init' );
- The following example is for adding a hook callback.
- // define the customize_controls_init callback
- function action_customize_controls_init( ) {
- // make action magic happen here...
- };
- // add the action
- add_action( 'customize_controls_init', 'action_customize_controls_init', 10, 0 );
- To remove a hook callback, use the example below.
- // remove the action
- remove_action( 'customize_controls_init', 'action_customize_controls_init', 10, 0 );
Defined (3)
The action is defined in the following location(s).
- /wp-admin/customize.php
- do_action( 'customize_controls_init' );
- /wp-includes/class-wp-customize-widgets.php
- add_action( 'customize_controls_init', array( $this, 'customize_controls_init' ) );
- /wp-includes/class-wp-customize-manager.php
- add_action( 'customize_controls_init', array( $this, 'prepare_controls' ) );