Lets say i have this kind of code:
$array = [
\'a\'=> [
\'b\' => [
\'c\'=>\'some value\',
],
Hi bro you can do it like this throught an array of keys :
This is your array structured :
$array = array(
'a'=> array(
'b' => array(
'c'=>'some value',
),
),
);
This is the PHP code to get value from your array with dynamic keys :
$result = $array; //Init an result array by the content of $array
$keys = array('a','b','c'); //Make an array of keys
//For loop to get result by keys
for($i=0;$i
I hope that the answer help you, Find here the PHPFiddle of your working code.