On this page
do_action( 'dynamic_sidebar_before', int|string $index, bool $has_widgets )
Fires before widgets are rendered in a dynamic sidebar.
Description
Note: The action also fires for empty sidebars, and on both the front end and back end, including the Inactive Widgets sidebar on the Widgets screen.
Parameters
$indexint|string-
Index, name, or ID of the dynamic sidebar.
$has_widgetsbool-
Whether the sidebar is populated with widgets.
Default true.
Source
File: wp-includes/widgets.php. View all references
do_action( 'dynamic_sidebar_before', $index, true );
Related
Used By
| Used By | Description |
|---|---|
| dynamic_sidebar() wp-includes/widgets.php | Display dynamic sidebar. |
Changelog
| Version | Description |
|---|---|
| 3.9.0 | Introduced. |
© 2003–2022 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/hooks/dynamic_sidebar_before