views:

154

answers:

2

Say if I am on page 1 , I enter my form data and go to page 2 , But wait I forgot something and I need to go back. FireFox and Safari ask me if I want to resend my form data.

But IE being IE it just goes back and does not show the page.

Is there away around this when I click back it keeps the data and the page appears.

Sorry I cannot give a link but the process for u to go through on my site to get to this part would take you a while.

+2  A: 

My suspicion is that your talking about a wizard form. Where each part of the form is a page and you can go backwards and forwards through the pages.

the back button has always caused problems for developers on the web and this is probably the most annoying.

You can stop the IE back button issue by redirecting on the server to the next page when you receive a form post rather than just delivering the form back to the browser. Doing this means that the browser considers each page to have been a get and stops asking you if you want to resubmit the form.

to do this simply make each form post to itself and then return a redirect to the next page of the wizard. I'd give examples but I'm not sure what language you are using on the server.

the other alternative is to use javascript to create a wizard from your form see this jQuery wizard form demo.

Matt Smith
What is a "wizard form" ?
Oliver Bayes-Shelton
Also I am using PHP does this help ?
Oliver Bayes-Shelton
A wizard form consists of multiple stages that are filled in one after the other and you can navigate backwards and forwards through the stages. a javascript example is here http://www.hazardouspursuits.co.uk/apply.
Matt Smith
+1  A: 

create a new back button besides the submit button and when a user clicks on either one you call a javascript function which modifies the form action either to the next page or the previous page.

Anas Toumeh