wppaste
WordPress

WP_Customize_Widgets

Since
3.9.0
Source
wp-includes/class-wp-customize-widgets.php:19
Customize Widgets class.

Description

Implements widget management in the Customizer.

Compatibility

WordPress
since 3.9.0
  • 6.7.7
  • 6.8.8
  • 6.9.7
  • 7.0.4
  • 7.1.0

Present in every tracked release (6.7.7 to 7.1.0).

Hooks and filters fired · 19

Every hook that fires from inside WP_Customize_Widgets, in the order it appears in the class, grouped by the method that fires it.

Properties · 15

$managerWP_Customize_Managerpublic
WP_Customize_Manager instance.
$core_widget_id_basesarrayprotected
All id_bases for widgets defined in core.
$rendered_sidebarsarrayprotected
$rendered_widgetsarrayprotected
$old_sidebars_widgetsarrayprotected
$selective_refreshable_widgetsarrayprotected
Mapping of widget ID base to whether it supports selective refresh.
$setting_id_patternsarrayprotected
Mapping of setting type to setting ID pattern.
$before_widget_tags_seenarrayprotected
List of the tag names seen for before_widget strings.
$sidebar_instance_countarrayprotected
Keep track of the number of times that dynamic_sidebar() was called for a given sidebar index.
$context_sidebar_instance_numberint|nullprotected
The current request's sidebar_instance_number context.
$current_dynamic_sidebar_id_stackarrayprotected
Current sidebar ID being rendered.
$rendering_widget_idstring|nullprotected
Current sidebar being rendered.
$rendering_sidebar_idstring|nullprotected
Current widget being rendered.
$_captured_optionsarrayprotected
List of captured widget option updates.
$_is_capturing_option_updatesboolprotected
Whether option capture is currently happening.

Methods · 67

Source code

#[AllowDynamicProperties]final class WP_Customize_Widgets { 	/**	 * WP_Customize_Manager instance.	 *	 * @since 3.9.0	 * @var WP_Customize_Manager	 */	public $manager; 	/**	 * All id_bases for widgets defined in core.	 *	 * @since 3.9.0	 * @var array	 */	protected $core_widget_id_bases = array(		'archives',		'calendar',		'categories',		'custom_html',		'links',		'media_audio',		'media_image',		'media_video',		'meta',		'nav_menu',		'pages',		'recent-comments',		'recent-posts',		'rss',		'search',		'tag_cloud',		'text',	); 	/**	 * @since 3.9.0	 * @var array	 */	protected $rendered_sidebars = array(); 	/**	 * @since 3.9.0	 * @var array	 */	protected $rendered_widgets = array(); 	/**	 * @since 3.9.0	 * @var array	 */	protected $old_sidebars_widgets = array(); 	/**	 * Mapping of widget ID base to whether it supports selective refresh.	 *	 * @since 4.5.0	 * @var array	 */	protected $selective_refreshable_widgets; 	/**	 * Mapping of setting type to setting ID pattern.	 *	 * @since 4.2.0	 * @var array	 */	protected $setting_id_patterns = array(		'widget_instance' => '/^widget_(?P<id_base>.+?)(?:\[(?P<widget_number>\d+)\])?$/',		'sidebar_widgets' => '/^sidebars_widgets\[(?P<sidebar_id>.+?)\]$/',	); 	/**	 * Initial loader.	 *	 * @since 3.9.0	 *	 * @param WP_Customize_Manager $manager Customizer bootstrap instance.

Changelog

Introduced in 3.9.0. Unchanged from 6.7.7 through 7.1.0.

  1. 6.7.7
  2. 6.8.8
  3. 6.9.7
  4. 7.0.4
  5. 7.1.0

Signature, return type and hooks compared across 5 parsed releases.

About this page

Parsed data
Generated from the wordpress-develop 6.9.7 tag, from src/wp-includes/class-wp-customize-widgets.php, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.
Corrections
Something wrong on this page? Report it and it gets fixed in the next regeneration.