PDA

View Full Version : goback and reload


loophole
04-22-2003, 07:24 AM
I have a button as follows.
<INPUT TYPE="button" VALUE="< Go Back" style="font-family: Verdana; font-size: 8pt; color: #FF0000" onClick="history.back()">

Now need to automatically refresh the page after going back. Since the page has form results the broswer is requesting to refresh.
Does anyone know what i can add to the onclick script to goback and then refresh automatically.


thanks,
Hasan

requestcode
04-22-2003, 01:30 PM
On the page your going back to you could try using the onLoad event in the body tag to reset the form.
<body onLoad="document.form_name.reset()">

Or in your go back button you could reference the page with the form directly by using location.href like this:
<INPUT TYPE="button" VALUE="< Go Back" style="font-family: Verdana; font-size: 8pt; color: #FF0000" onClick="location.href='formpage.html'">