SWFAddress 2.2 & onInit AS2.0

Hi Folks,

I cannot for the life of me figure out how to grab the current URL and pass it to SWFAddress onInit/onLoad. What I’m trying to accomplish is being about to send a url like:

http://www.creataVivendi.com/#/contact-us

using:


SWFAddress.onInit = function(){
	checkURL();
}

function checkURL(){
	currentURL = SWFAddress.getValue().split("/").join("");
	getURL("javascript:alert('"+currentURL+"')");
}


The checkURL() function works once initialized (from “normal” function calls etc) but not onLoad/Init. It returns nothing (or “/” before I split the string). I want do determine what section to go to on arrival if anything other than /. Is there a way to do this?

Thanks in Advance!

  • Nixon