WP_Customize_Widgets::schedule_customize_register()

In this article

Ensures widgets are available for all types of previews.

Description

When in preview, hook to ‘customize_register’ for settings after WordPress is loaded so that all filters have been initialized (e.g. Widget Visibility).

Source

public function schedule_customize_register() {
	if ( is_admin() ) {
		$this->customize_register();
	} else {
		add_action( 'wp', array( $this, 'customize_register' ) );
	}
}

Changelog

VersionDescription
3.9.0Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.