WP_Widget_Area_Customize_Control::to_json() WordPress Method

The WP_Widget_Area_Customize_Control::to_json() method is used to generate a JSON representation of the widget area control. This is used to send the data to the client side where it can be used to create a new widget area.

WP_Widget_Area_Customize_Control::to_json() #

Refreshes the parameters passed to the JavaScript via JSON.


Source

File: wp-includes/customize/class-wp-widget-area-customize-control.php

	public function to_json() {
		parent::to_json();
		$exported_properties = array( 'sidebar_id' );
		foreach ( $exported_properties as $key ) {
			$this->json[ $key ] = $this->$key;
		}
	}


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.