WP_REST_Sidebars_Controller::retrieve_widgets() WordPress Method

The WP_REST_Sidebars_Controller::retrieve_widgets() method is used to retrieve the list of widgets for a sidebar. This is useful for displaying a list of widgets in a sidebar management screen.

WP_REST_Sidebars_Controller::retrieve_widgets() #

Looks for “lost” widgets once per request.


Description

Top ↑

See also


Top ↑

Source

File: wp-includes/rest-api/endpoints/class-wp-rest-sidebars-controller.php

	protected function retrieve_widgets() {
		if ( ! $this->widgets_retrieved ) {
			retrieve_widgets();
			$this->widgets_retrieved = true;
		}
	}


Top ↑

Changelog

Changelog
VersionDescription
5.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.