WP_Customize_Manager::get_panel() WordPress Method

The WP_Customize_Manager::get_panel() method retrieves a panel by its ID. This is useful for retrieving a panel object in order to modify its properties or call its methods.

WP_Customize_Manager::get_panel( string $id ) #

Retrieves a customize panel.


Parameters

$id

(string)(Required)Panel ID to get.


Top ↑

Return

(WP_Customize_Panel|void) Requested panel instance, if set.


Top ↑

Source

File: wp-includes/class-wp-customize-manager.php

	public function get_panel( $id ) {
		if ( isset( $this->panels[ $id ] ) ) {
			return $this->panels[ $id ];
		}
	}

Top ↑

Changelog

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

Show More