PDA

View Full Version : getURL doesn't work when use with load movie


primablinki
03-18-2005, 07:32 AM
Hi,

I search all over the forum and on the net but I can't find anything that solves this problem. I was using the getURL tutorial from kirupa and it works fine when I am just loading the swf alone. When I load it into my index movie into an empty movie clip, the window doesn't pop up anymore. I tried different browsers and it doesn't load. i also tried change the button symbol to a movie clip and call it from the main timeline and it doesn't work either. the tutorial is here: http://www.kirupa.com/developer/mx/centered_popup.htm, and I haven't change its code much. can anyone help please?

Cota
03-18-2005, 06:00 PM
Post your current code so that we may see what changes you have made.

primablinki
03-18-2005, 07:31 PM
this is the code i put with the button that loads getURL:
on (release) {
address = "milanFinal2.html";
target_winName = "kirupa";
width = 600;
height = 460;
toolbar = 0;
location = 0;
directories = 0;
status = 0;
menubar = 0;
scrollbars = 0;
resizable = 0;
//sends data back to the function
openWinCentre(address, target_winName, width, height, toolbar, location, directories, status, menubar, scrollbars, resizable);
}

this is the frame action:
stop();

_root.openWinCentre = function (url, winName, w, h, toolbar, location, directories, status, menubar, scrollbars, resizable) {

getURL ("javascript:var myWin; if(!myWin || myWin.closed){myWin = window.open('" + url + "','" + winName + "','" + "width=" + w + ",height=" + h + ",toolbar=" + toolbar + ",location=" + location + ",directories=" + directories + ",status=" + status + ",menubar=" + menubar + ",scrollbars=" + scrollbars + ",resizable=" + resizable + ",top='+((screen.height/2)-(" + h/2 + "))+',left='+((screen.width/2)-(" + w/2 + "))+'" + "')}else{myWin.focus();};void(0);");
}

Thanks a lot! tell me if more info is needed

primablinki
03-18-2005, 08:52 PM
here are the files. interactionMain9Test.fla is where the button is.(in frame3)
menuFinal2Test calls emptyClip2 to load interactionMain9Test and master is where emptyClip2 is constructed originally.

http://www.sfu.ca/~lhuia/upload.zip

Thanks!!