A WordPress-centric search engine for devs and theme authors



dynamic_sidebar ›

Since3.0.0
Deprecatedn/a
do_action( 'dynamic_sidebar', $wp_registered_widgets[ $id ] )
Parameters:
  • (array) $widget_id { An associative array of widget arguments. @type string $name Name of the widget. @type string $id Widget ID. @type array|callable $callback When the hook is fired on the front end, $callback is an array containing the widget object. Fired on the back end, $callback is 'wp_widget_control', see $_callback. @type array $params An associative array of multi-widget arguments. @type string $classname CSS class applied to the widget container. @type string $description The widget description. @type array $_callback When the hook is fired on the back end, $_callback is populated with an array containing the widget object, see $callback. }
    Required: Yes
Defined at:
Codex:

Fires before a widget's display callback is called.

Note: The action fires on both the front end and back end, including for widgets in the Inactive Widgets sidebar on the Widgets screen.

The action is not fired for empty sidebars.





Source

do_action( 'dynamic_sidebar', $wp_registered_widgets[ $id ] );