View Full Version : Close window - the whole frameset?

JS Novice
12-05-2004, 12:19 PM
I need a button which does the same as pressing Alt+F4, that is, closing the entiered browser window, even if it consists of several pages running in frames in full screen mode. The button (or link) are to be placed only once in the browser window, that is, only in one frame. When pushed, all frames and the browser window should close.

Is it possible? Can anybody help? If so, please answer! :confused:

12-05-2004, 01:10 PM
<a href="javascript:window.close();">Close</a>

Does that code work?


JS Novice
12-11-2004, 08:53 PM
Unfortunately not :( Your suggestion works well for windows with single page whitin. It doesn't work for pages in a set of frames.. Other suggestions, pleazzze! :confused:

12-14-2004, 11:37 AM
<a href="javascript:' '" onClick="top.close()">Close</a>

12-14-2004, 11:38 AM
Or obviously <a href="javascript:top.close();">Close Frameset</a> would be a lot neater.

JS Novice
12-15-2004, 10:45 PM
TNX, a lot!! :) :) :)