# Kirupa tute worked great! Until

**URL:** <https://forum.kirupa.com/t/kirupa-tute-worked-great-until/230281>\
**Category:** Uncategorized\
**Created:** [June 25, 2007, 1:37am UTC](https://forum.kirupa.com/t/kirupa-tute-worked-great-until/230281 "2007-06-25T01:37:23Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![will\_s](https://avatars.discourse-cdn.com/v4/letter/w/d2c977/32.png) [@will\_s](https://forum.kirupa.com/u/will_s)\
**Post date:** [June 25, 2007, 1:37am UTC](https://forum.kirupa.com/t/kirupa-tute-worked-great-until/230281/1 "2007-06-25T01:37:23Z")

</div>

Hi,  
I just used Kirupa’s tutorial, “Launching a Centered Pop-Up Window”  
[http://www.kirupa.com/developer/mx/centered\_popup.htm](http://www.kirupa.com/developer/mx/centered_popup.htm)  
with great success.

It worked just like it was supposed to–in a test-page situation.

But when I tried to transfer it to my real-life situation, it refused to work.

My reality involves the test-page being called into a situation like this:  
/\*  
\_root.createEmptyMovieClip(“loadExternalSwiffs\_mc”, 1);  
loadExternalSwiffs\_mc.\_x = 0;  
loadExternalSwiffs\_mc.\_y = 103;  
\_root.loadExternalSwiffs\_mc.loadMovie(“introSplashPage.swf”)  
\*/

Only it’s even more complicated than that because the test-page isn’t that introSplashPage, it’s one (called "aaronCreditsList.swf) that’s being loaded into that level from a button inside the root document, like this:  
/\*  
on (release) {  
\_root.loadExternalSwiffs\_mc.loadMovie(“aaronCreditsList.swf”)  
gotoAndStop(“collapsed2”);  
gotoAndStop(“collapsed”);  
}  
\*/

I guess what I need to know is where–now–to put this Kirupa copy:  
/\*  
\_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);");

}
*/

```

And/or how to modify it slightly so that it can “find” its way to Kirupa’s button copy:  
/\* on (release) {

```
//customize the window that gets opened
// 0 equals NO.
// 1 equals YES.
address = "aaronCreditsActor.html";
target_winName = "mainWindow";
width = 700;
height = 350;
toolbar = 0;
location = 0;
directories = 0;
status = 0;
menubar = 0;
scrollbars = 1;
resizable = 0;
//sends data back to the function
openWinCentre(address, target_winName, width, height, toolbar, location, directories, status, menubar, scrollbars, resizable);

}

```

\*/

I’ve tried a bunch of things but, so far, nothing has worked.

TIA
