Closed Thread Icon

Preserved Topic: simple "close browser" command Pages that link to <a href="https://ozoneasylum.com/backlink?for=18104" title="Pages that link to Preserved Topic: simple &amp;quot;close browser&amp;quot; command" rel="nofollow" >Preserved Topic: simple &quot;close browser&quot; command\

 
Author Thread
Radical Rob
Bipolar (III) Inmate

From: Kapolei, Hawaii USA
Insane since: Jun 2001

posted posted 08-10-2001 02:11

Does anyone have a simple "CLOSE BROWSER" command. I for the life of god cannot figure it out. Reason is I have a site
Im working on that has a certain window that pops open to show categories and award winners but I want ot have a CLOSE WINDOW like on the page so i dont clutter the screen with irritating pop ups.

thanks!



wayoutwestenterprises.com

fallen
Bipolar (III) Inmate

From: A ripped t-shirt pocket.
Insane since: Aug 2000

posted posted 08-10-2001 02:15

<a href="javascript:window.close()">close</a>
or use

self.close()

instead of window.close()


[dis]contempt+[.org]


[This message has been edited by fallen (edited 08-10-2001).]

[This message has been edited by fallen (edited 08-10-2001).]

Slime
Lunatic (VI) Mad Scientist

From: Massachusetts, USA
Insane since: Mar 2000

posted posted 08-10-2001 02:49

Or use

self.window.window.self.self.self.window.self.window.self.window.close();

since the self object and window object are exactly the same thing, and they're both references to the top level object. You could actually use just

close();

because any statement you execute is executed under the Window object without you having to specify it. The Window object contains the handy "window" and "self" reference to *itself*.

If that made no sense, forget about it. =)

fallen
Bipolar (III) Inmate

From: A ripped t-shirt pocket.
Insane since: Aug 2000

posted posted 08-10-2001 02:53

or you could get real nifty and have an <body onload="javascript:window.open('remotecontrol.html')> and then from your remote control have all the names of the window listed in an array and use <a href="javascript:window.close('windownamearray')">kill all windows</a> and then rip use some dhtml fireworks.


[dis]contempt+[.org]

Radical Rob
Bipolar (III) Inmate

From: Kapolei, Hawaii USA
Insane since: Jun 2001

posted posted 08-14-2001 23:11

That worked! thanks. Is there another way of doing it without asking for permission to be closed?



wayoutwestenterprises.com

Slime
Lunatic (VI) Mad Scientist

From: Massachusetts, USA
Insane since: Mar 2000

posted posted 08-14-2001 23:21

If your script opened the window, then it can be closed without an automatic pop-up. But you can't close the window the user opened themselves without their permission. (And thank goodness, a site that did that would make me mad.)

« BackwardsOnwards »

Show Forum Drop Down Menu