Description
Finds a value within a multi level array. Forward slashes ( / ) are used to descend down the structure of the array.
Usage
rgars( $array, $name );
Parameters
- $array array
The array that you want to obtain a value from.
-
$name string
The array keys, separated by a forward slash, to be located.
Examples
// Defines the multilevel array, and transcends it to get the value.
$array = array(
'firstlevel' => array(
'secondlevel' => array(
'thirdlevel' => 'Desired Value'
)
)
)
$name = 'firstlevel/secondlevel/thirdlevel';
rgars( $array, $name );
Source Code
This function is located in gravityforms.php