How to take URL and split/string to get URL variables in Flash AS3

Posted by Leon on Stack Overflow See other posts from Stack Overflow or by Leon
Published on 2010-04-27T21:20:43Z Indexed on 2010/04/27 21:23 UTC
Read the original article Hit count: 356

So I have a URL that I need my Flash movie to extract variables from:

example link:
http://www.example.com/example_xml.php?aID=1234&bID=5678

I need to get the aID and the bID numbers.

I'm able to get the full URL into a String via ExternalInterface

var url:String = ExternalInterface.call("window.location.href.toString");
if (url) testField.text = url;

Just unsure as how to manipulate the String to just get the 1234 and 5678 numbers.

Appreciate any tips, links or help with this!

© Stack Overflow or respective owner

Related posts about flash

Related posts about actionscript-3