Question

I came across this array structure, with a "[data] array" I don't know what it is, and I don't know how to bypass it to print, for example [0]['email']. ['data'][0]['email'] doesn't seem to work either. How can I do this?

Array ( [data] => Array ( [0] => Array ( [email] => xxx@xxx.com ) [1] => Array ( [email] => xxx@xxx.com ) ) ) 
Was it helpful?

Solution

$varname['data'][0]['email'] should work. Don't you forget to address array variable itself?

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top