apply_filters( 'dynamic_sidebar_has_widgets', bool $did_one, int|string $index )

Filters whether a sidebar has widgets.

Description Description

Note: The filter is also evaluated for empty sidebars, and on both the front end and back end, including the Inactive Widgets sidebar on the Widgets screen.

Top ↑

Parameters Parameters


(bool) Whether at least one widget was rendered in the sidebar. Default false.


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

Top ↑

Source Source

File: wp-includes/widgets.php

View on Trac

Top ↑

Changelog Changelog

Version Description
3.9.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.