/ Published in: ActionScript 3
It's not the prettiest piece of code but it works for now
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
import flash.external.ExternalInterface; var fullurl:String = ExternalInterface.call("window.location.href.toString"); if(fullurl){ var params:Array = fullurl.split('?'); fullurl = params[1]; params = fullurl.split('&'); var length:uint = params.length; var g:uint; for (g=0; g< length; g++){ var index:int=0; var kvPair:String = params[g]; if((index = kvPair.indexOf("=")) > 0){ var key:String = kvPair.substring(0,index); var value:String = kvPair.substring(index+1); params[key] = value; } } }