I have an array of data in a string called $data that looks like this:
code:-------------------------------------------------
<form>
<person>
<email caption = email>joe@domain.com</email>
<person>
<form>
What I want to do is return this
email
joe@domain.com
using this code
PHP:-------------------------------------------------
$person =& $data["FORM"][0]["PERSON"];
foreach ($person as $pers)
{
echo "\n<br>" . $pers["EMAIL"][0]["CAPTION"];
echo "\n<br>" . $txctrls["EMAIL"][0]["value"];
}
for some reason it will only return the CAPTION i.e. email
I have tried having value in both upper and lower case and it does not work.
when I print_r my whole $data array all the tags are in upper case apart from the value ones so, I assume lower case is correct.
What am I doing wrong?