dynamic_sidebar_after хук-событие . WP 3.9.0
Fires after widgets are rendered in a dynamic sidebar.
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.
Использование
add_action( 'dynamic_sidebar_after', 'action_function_name_6209', 10, 2 ); function action_function_name_6209( $index, $has_widgets ){ // action... }
- $index(число/строка)
- Index, name, or ID of the dynamic sidebar.
- $has_widgets(true/false)
- Whether the sidebar is populated with widgets.
По умолчанию: true
Список изменений
С версии 3.9.0 | Введена. |
Где вызывается хук
dynamic_sidebar_after
wp-includes/widgets.php 844
do_action( 'dynamic_sidebar_after', $index, true );
wp-includes/widgets.php 700
do_action( 'dynamic_sidebar_after', $index, false );
Где используется хук в ядре WordPress
wp-includes/widgets.php 1628
add_action( 'dynamic_sidebar_after', array( $this, 'end_dynamic_sidebar' ) );