Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how to deal with 'Web Page Expired'

Status
Not open for further replies.

alfalf

Programmer
Mar 6, 2003
155
BA
Hello all.

I have an form (POST submitted to php script). I do validation on that form, and if someone misses to fill something, it reloads itself (when Submit button pressed) pointing to missing or bad data. Then when everythings ok, the form is submitted to another page. The problem that occures is when user presses Back button on browser, I got this 'Web Page Expired' message.

Now, I know why is that - because data is already POSTED and connection with server is closed. But I don't know how to overcome this (if it is possible).

Any suggestion is appreciated. Thanks.
 
Try making the form open a new page when it is submitted. This way the person already has the last page up.
 
Try making the form open a new page when it is submitted.
That'd be very irritating. Don't do that.

But I don't know how to overcome this (if it is possible).
I don't think it's possible to change what the browser does when you press [Back]. You're gonna have to live with that.

Where/why are they pressing the Back button? Maybe you can provide your own button on-screen when the form has been entered fully and correctly that they can press to change anything that they want to. It would re-display the form with all the fields filled in (much like your existing error handling method).

-- Chris Hunt
Webmaster & Tragedian
Extra Connections Ltd
 
Store the form info in session variables then populate the form with them.

If it's the first time the user has come to the form then it will be empty (as there are no session vars to populate it with).
When they go back to the form it *should* populate with the info they entered into the form (which was subsequently stored as session vars).

I really have no idea whether this will work... it's just off the top of my head. :)

Foamcow Heavy Industries - Web design and ranting
Target Marketing Communications - Advertising, Direct Marketing and Public Relations
I wonder what possesses people to make those animated gifs. Do you just get up in the morning and think, "You know what web design r
 
That'd be very irritating.
I'm not quite sure how it would be irritating. I mean its not like everything you click on opens a new window. If this is one of the few occasions then it should be fine.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top