WP_Customize_Setting::multidimensional_get( $root,  $keys, mixed $default = null )

Will attempt to fetch a specific value from a multidimensional array.


Description Description


Parameters Parameters

$root

(Required)

$keys

(Required)

$default

(mixed) (Optional) A default value which is used as a fallback. Default is null.

Default value: null


Top ↑

Return Return

(mixed) The requested value or the default value.


Top ↑

Source Source

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

	final protected function multidimensional_get( $root, $keys, $default = null ) {
		if ( empty( $keys ) ) { // If there are no keys, test the root.
			return isset( $root ) ? $root : $default;
		}

		$result = $this->multidimensional( $root, $keys );
		return isset( $result ) ? $result['node'][ $result['key'] ] : $default;
	}

Top ↑

Changelog Changelog

Changelog
Version Description
3.4.0 Introduced.


Top ↑

User Contributed Notes User Contributed Notes

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