File: wp-includes/widgets.php
-
Registers the previous theme’s sidebars for the block themes.
-
functionwp_get_sidebar()
Retrieves the registered sidebar with the given ID.
-
functionwp_find_widgets_sidebar()
Finds the sidebar that a given widget belongs to.
-
functionwp_assign_widget_to_sidebar()
Assigns a widget to the given sidebar.
-
functionwp_render_widget()
Calls the render callback of a widget and returns the output.
-
functionwp_render_widget_control()
Calls the control callback of a widget and returns the output.
-
functionwp_check_widget_editor_deps()
Displays a _doing_it_wrong() message for conflicting widget editor scripts.
-
functionwp_setup_widgets_block_editor()
Enables the widgets block editor. This is hooked into ‘after_setup_theme’ so that the block editor is enabled by default but can be disabled by themes.
-
functionwp_use_widgets_block_editor()
Determines whether or not to use the block editor to manage widgets.
-
Filters whether to use the block editor to manage widgets.
-
functionwp_parse_widget_id()
Converts a widget ID into its id_base and number components.
-
Filters the sidebar default arguments.
-
Compares a list of sidebars with their widgets against an allowed list.
-
functionwp_map_sidebars_widgets()
Compares a list of sidebars with their widgets against an allowed list.
-
functionis_registered_sidebar()
Checks if a sidebar is registered.
-
hookwidgets_init
Fires after all default WordPress widgets have been registered.
-
functionwp_widget_rss_output()
Displays the RSS entries in a list.
-
functionwp_widget_rss_form()
Displays RSS widget options form.
-
functionwp_widget_rss_process()
Processes RSS feed widget data and optionally retrieve feed items.
-
functionwp_widgets_init()
Registers all of the default WordPress widgets on startup.
-
functionretrieve_widgets()
Validates and remaps any “orphaned” widgets to wp_inactive_widgets sidebar, and saves the widget settings. This has to run at least on each theme change.
-
function_wp_sidebars_changed()
Handles sidebars config after theme change.
-
functionis_active_sidebar()
Determines whether a sidebar contains widgets.
-
Filters whether a dynamic sidebar is considered “active”.
-
functionwp_unregister_widget_control()
Removes control callback for widget.
-
functionwp_get_sidebars_widgets()
Retrieves the full list of sidebars and their widget instance IDs.
-
functiondynamic_sidebar()
Displays dynamic sidebar.
-
hooksidebars_widgets
Filters the list of sidebars and their widgets.
-
Fires before widgets are rendered in a dynamic sidebar.
-
functionwp_set_sidebars_widgets()
Sets the sidebar widget option to update sidebars.