Self.close() window without the dialog close?Yes/NO


W

Walter Beierdonck

Hi,

I've written a script dat has to run with a windows-shortcut... ex:
http://www.domein.com/script.php

This is my script:
<html>
<head>
<script>
var howLong = 2000;
t = null;
function closeMe(){
t = setTimeout("self.close()",howLong);
}
</script>
</head>

<BODY ONLOAD='window.closeMe()'>
<h1>hello this box has to appaer for 2 seconds and has to close without a
dialog box</h1>
</body>
</html>

the problem is that after 2sec. a dialog box appear on my screen ask for
closing this window

Can some one help me so this dialog-box doesn't appear en the window just
close

thx,
 
Ad

Advertisements

G

Grant Wagner

Walter said:
Hi,

I've written a script dat has to run with a windows-shortcut... ex:
http://www.domein.com/script.php

This is my script:
<html>
<head>
<script>
var howLong = 2000;
t = null;
function closeMe(){
t = setTimeout("self.close()",howLong);
}
</script>
</head>

<BODY ONLOAD='window.closeMe()'>
<h1>hello this box has to appaer for 2 seconds and has to close without a
dialog box</h1>
</body>
</html>

the problem is that after 2sec. a dialog box appear on my screen ask for
closing this window

Can some one help me so this dialog-box doesn't appear en the window just
close

No. There is no way to reliably close a window you did not open with script, or
that has history without the browser either a) not honoring the request
silently or b) prompting you.

--
| Grant Wagner <[email protected]>

* Client-side Javascript and Netscape 4 DOM Reference available at:
*
http://devedge.netscape.com/library/manuals/2000/javascript/1.3/reference/frames.html

* Internet Explorer DOM Reference available at:
*
http://msdn.microsoft.com/workshop/author/dhtml/reference/dhtml_reference_entry.asp

* Netscape 6/7 DOM Reference available at:
* http://www.mozilla.org/docs/dom/domref/
* Tips for upgrading JavaScript for Netscape 7 / Mozilla
* http://www.mozilla.org/docs/web-developer/upgrade_2.html
 

Top