I am having a few issues searching a multi-dimensional array which has been created an xml file. The xml files may vary and I want to be able to search for a a key and output some values but am stuck! :queasy:
The array looks something like this:
Array (
[gallery] => Array (
[_c] => Array (
[title] => Array (
[_v] => Architecture
)
[paypal] => Array (
[_a] => Array (
[custom] => true
[default] => true
)
[_c] => Array (
[option] => Array (
[0] => Array (
[_c] => Array (
[size] => Array (
[_v] => 6x9
)
[price] => Array (
[_v] => 7
)
[finish] => Array (
[0] => Array (
[_v] => Gloss
)
[1] => Array (
[_v] => Matte
)
)
)
)
)
[disclaimer] => Array (
[_v] => alsorts of stuff
)
)
)
[exif] => Array (
[_a] => Array (
[enable] => false
)
[_c] => Array (
[detail] => Array (
[0] => Array (
[_v] => comment
)
[1] => Array (
[_v] => iso
)
[2] => Array (
[_v] => aperture
)
[3] => Array (
[_v] => shutter speed
)
[4] => Array (
[_v] => focal length
)
)
)
)
)
)
)
In this instance, I am trying to search for the presence '[disclaimer]' and if it is there, output its contents, in this instance the value of [_v] ('alsorts of stuff '). I have looked on the manual pages and found various multi-dimensional array recursive search functions but haven't managed to get anything working.
I appreciate this array is complicated.
Any help would be very gratefully accepted as I am stumped!
Thank you
Alex