I have a button inside of a movie clip that has the following code/javascript. When executed on the main stage, it is fine, but not inside a movie clip.

[CODE] on (release) {
screenX = System.capabilities.screenResolutionX;
screenY = System.capabilities.screenResolutionY;
screenW = 611;
screenH = 400;
screenT = ((screenY-screenH)/2);
screenL = ((screenX-screenW)/2);
url = "gallery.html";
getURL("javascript:NewWindow=window.open('"+url+"' ,'windowname','width="+screenW+",height="+screenH+ ",top="+screenT+",left="+screenL+",toolbar=No,loca tion=Center,scrollbars=No,status=No,resizable=No,f ullscreen=No');NewWindow.focus();void(0);");
}