I need an html page that when visited automatically redirects the browser to return to the previous page it was on. here is the current code I have:
this works in firefox but in IE you have to press ok in the alert box before it returns. I admit I am a javascript novice. Any suggestions
Code:
<head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title>Untitled Document</title> <script type="text/javascript"> function load() { history.go(-1) alert(""); } </script> </head> <body onload="load()"> <input type="button" value="Back" onclick="goBack()" /> </body> </html>
Comment