The quick question thread

Currently reading:
The quick question thread

JavaScript.....

I have a script that closes down the web browser once users have finished filling in my form.


<script language=JavaScript>
<!--

function closeIt() {
close();
}

// -->
</script>

<center>
<form>Thank you for submitting.<br><input onclick=closeIt() type=button value="Close Window"> </form></center><!-- End of Close Browser Script -->

At the moment it prompts them to close browser after they click the button. I would like it just to close the program straight away (like pressing alt+F4)

Do I have to add ALT+F4 into the script somewhere?

Any java geeks:p
 
<body onload="opener=self;self.close()">

that will work but only in some browsers

people think of it as a hack or malicious code becuase it doesnt prompt

people dont understand thats its also a way of stream lining online applications
 
Back
Top