Receive an array from PHP

How can I in as 3.0 receive an array

Page 1 of 1

4 Replies - 3436 Views - Last Post: 24 March 2009 - 09:57 AM

#1 amexudo   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 10
  • Joined: 14-March 09

Receive an array from PHP

Posted 22 March 2009 - 02:28 PM

Hello,
i already figured out how i can send an array from as3 to php with the toString() method.
Now i'm looking for the solution to how do I receive an array from php. I would like to print an array and access it inside my actionscript file as an array? Is there a way to parse it?
Thank you very much for the help.
Is This A Good Question/Topic? 0
  • +

Replies To: Receive an array from PHP

#2 theRemix   User is offline

  • D.I.C Regular

Reputation: 15
  • View blog
  • Posts: 440
  • Joined: 19-October 05

Re: Receive an array from PHP

Posted 23 March 2009 - 01:10 AM

print_r(myArray)

http://us3.php.net/print_r

?
Was This Post Helpful? 0
  • +
  • -

#3 CyanBlue   User is offline

  • D.I.C Head
  • member icon

Reputation: 6
  • View blog
  • Posts: 156
  • Joined: 01-September 06

Re: Receive an array from PHP

Posted 23 March 2009 - 10:06 AM

If you'd like to send/receive an array or an object between Flash and PHP, you'd need to use Flash Remoting to do so... Otherwise, you'd need to create a string out of your PHP array and send it back to Flash then recreate an array with that data...

CyanBlue
Was This Post Helpful? 0
  • +
  • -

#4 amexudo   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 10
  • Joined: 14-March 09

Re: Receive an array from PHP

Posted 23 March 2009 - 11:47 PM

Thank you very much for your help!
Was This Post Helpful? 0
  • +
  • -

#5 CyanBlue   User is offline

  • D.I.C Head
  • member icon

Reputation: 6
  • View blog
  • Posts: 156
  • Joined: 01-September 06

Re: Receive an array from PHP

Posted 24 March 2009 - 09:57 AM

You're very welcome... ;)
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1