I have this:
Array
(
[carx] => Array
(
[no] => 63
)
[cary] => Array
(
[no] => 64
So you don't you your id key for the first level, so loop through and when you find a match stop looping and break out of the foreach
$id = 0;
$needle = 63;
foreach($array as $i => $v)
{
if ($v['no'] == $needle)
{
$id = $i;
break 1;
}
}
// do what like with any other nested parts now
print_r($array[$id]);
Then you could use that key to get the whole nested array.