/ Published in: ActionScript 3
URL: http://www.destroyyourcomputer.com
Expand |
Embed | Plain Text
//actionscript 3 import flash.net.URLRequest; import flash.net.URLLoader; import com.adobe.serialization.json.JSON; var loader:URLLoader = new URLLoader(); loader.load(new URLRequest("http://localhost/flash/person.php")); loader.addEventListener(Event.COMPLETE, onComplete_handler); function onComplete_handler(event:Event) { var person:Object=JSON.decode(event.target.data); trace(person[0].firstname + " " + person[0].lastname); trace(person[1].firstname +" " +person[1].lastname); }
You need to login to post a comment.
