|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Hello
is there any way to close a browser window using a button? I have a new window opening with some information, and I want it to close completely (ie not go to another URL or anything) when they click another button. Thank you! Sue ![]() |
|
#2
|
|||
|
|||
|
hi there,
try this: <input type="button" name="whatever" value="whatever" onClick="window.close()"> |
|
#3
|
|||
|
|||
|
Here's a way to close the browser window using and image as your trigger.
First define an internal anchor on your page. Then wrap the image in a href tag pointing at the anchor but add the onclick code in the href to close the window. For example - <a href="top" onClick="window.close();"> <img src="generic image"> </a> One cool side benefit is no annoying jscript "Close Window" warning. Hope this helps. URL K |
![]() |
| Viewing: Dev Shed Forums > Web Design > HTML Programming > close browser window |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|