dynamic_sidebar_after WordPress Action Hook

The dynamic_sidebar_after hook is called after the dynamic sidebar is displayed. This hook can be used to add additional content after the sidebar, such as a "Subscribe" call to action or social media icons.

do_action( 'dynamic_sidebar_after', int|string $index, bool $has_widgets ) #

Fires after 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.


Top ↑

Parameters

$index

(int|string)Index, name, or ID of the dynamic sidebar.

$has_widgets

(bool)Whether the sidebar is populated with widgets. Default true.


Top ↑

Source

File: wp-includes/widgets.php

View on Trac



Top ↑

Changelog

Changelog
VersionDescription
3.9.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.