views:

143

answers:

1

hi, i am having this hard time figuring what is needed to do, i am using URLVariables to send/recieve values between flash and PHP

the problem is, i am unable to access nested arrays ( array inside an array ) with flash

heres an example:

$dgresult = array("total" => $results); echo http_build_query($dgresult,"flf_");

in flash, all i need to do is to use: var variables:URLVariables = new URLVariables(e.target.data);

then i can access it with : variables.total

the problem now is when i have nested arrays:

$dgresult = array("total" => $results); array_push($dgresult,$another_array); http_build_query($dgresult,"flf_");

i can still access variables.total

but what about anything that has flf_ ? how is that possible?

+1  A: 

you should try to simply use established formats for complex data, such as JSON. For PHP see here and for AS3 see here. Or ready made solutions such as AMFPHP.

greetz
back2dos

back2dos
Right, i have used JSON functions to enhance the output to an acceptable level in Flash. Thanks.
Mahmoud