Phew .. Fixed it with ..
<HEAD>
<script language="javascript"> <!--
// this code and associated form is to workaround
// a bug in Internet Explorer that will show a cached version
// when the back button is used. the reload is not
// triggered by Netscape since it properly never gets
// the page from the cache.
function onload_reloadme () {
if (document.reloadme_form.reloadme_field.value == "reloadme" ) {
self.location.reload(true)
} else {
document.reloadme_form.reloadme_field.value = "reloadme";
}
// set the focus to the first non-hidden field on the second
// form - the first form is always the reloadme_form below.
if (document.forms[1]) {
for (i=0; i<document.forms[1].elements.length; i++) {
if (document.forms[1].elements[i].type.toLowerCase() != "hidden") {
document.forms[1].elements[i].focus();
break;
}
}
}
}
// -->
</script>
<form name="reloadme_form"><input type=hidden name="reloadme_field"
value="dontreloadme"></form>
</HEAD>
<BODY onLoad="onload_reloadme()">
Regards
Stephen
-----Original Message-----
From: Stephen Pope
Sent: 31 October 2003 09:06
To: [EMAIL PROTECTED]
Subject: [ cf-dev ] OT - Page Expiring
Lo all,
I have a web-page (really ? tell us more!), after the form is submitted and
it goes to the next page I need to ensure that if the user clicks the back button the
previous page will be expired and require them to reload. Good ol' pragma no cache
doesn't seem to be working.. I was wondering about a piece of javascript to run once
when the page is loaded to refresh .. but I am clueless about javascript etc so I have
no idea if you can get something to just run one (im guessing with an onload command
?!?). The problem is the page has a random ref. code on it that needs to be
regenerated (don't blame me, im fixing someone elses gay0r code and I have no time to
sort the whole damn thing out!) and people are entering one lot of details .. clicking
back a bunch of times and then entering more details but they have the same ref code !
Any help much appreciated ! (I know its Friday ! - If I could, id put the whole lot in
a bin and burn it but I have no choice ! :�) )
(Happy Halloween btw)
Stephen Pope
Web Developer
Eduserv Internet
managed hosting and development
_____
[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
tel: +44 (0)1225 474300
fax: +44 (0)1225 474301
http://www.eduserv.org.uk/internet/
_____
Eduserv Internet is a service of Eduserv Technologies Ltd
--
** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]