Pop up window problem::HELP

Hi there
am using flash, php and mysql to create an application. Throughout this i need to allow users to open files which is where i use javascript to open them in a new window. THe problem is that I keep getting this error when i try to access the files remotely through the website but it seems to work when i test using local host…its driving me mad!! Doea anyone know the answer?? Here is the error message i keep gett and after that I have inserted the javascript i use to open a new window. Hope someone can help!
[color=red]Line: 1
Char: 1
Error: The callee (server[not server application]) is not available and disappeared; all connections are invalid. The call did not execute.
Code: 0[/color]
[color=#ff0000][/color]
[color=black]And the js is as follows:[/color]

[size=2][color=seagreen]<SCRIPT LANGUAGE=“JavaScript”>[/color]

[color=seagreen]var newwin;[/color]

[color=seagreen]function launchwin(winurl,winname,winfeatures)[/color]

[color=seagreen]{[/color]

[color=seagreen]//This launches a new window and then[/color]

[color=seagreen]//focuses it if window.focus() is supported.[/color]

[color=seagreen]newwin = window.open(winurl,winname,winfeatures);[/color]

[color=seagreen]if(javascript_version > 1.0)[/color]

[color=seagreen]{[/color]

[color=seagreen]//delay a bit here because IE4 encounters errors[/color]

[color=seagreen]//when trying to focus a recently opened window[/color]

[color=seagreen]setTimeout(‘newwin.focus();’,250);[/color]

[color=seagreen]}[/color]

[color=seagreen]}[/color]

[color=seagreen]</SCRIPT>[/color]

[/size]