Miichael Posted September 25, 2006 Share Posted September 25, 2006 HelloI am pretty sure that this is not a strictly php question, but I thought I'd ask as my research is coming up empty.I have a case where the user fills out an order entry from and then goes to the next page to verfiy the order. At that point the user can submit the order or revise the order.I am assuming that the user clicks the browser back key to return to the previous page.What I would like to do is have the order entry form expire after a given time. By this I mean if the user tries to use the back key to return to the order form after 5 minutes, for example, they will see a message that the page has expired and they have to start over, but if they return in under 5 minutes the page will remain intact and they can modify as needed and then resubmit.I have not been able to find any information that is helpful. If someone could point me in the right direction I would appreciate it.Thank you. Quote Link to comment Share on other sites More sharing options...
Jocka Posted September 25, 2006 Share Posted September 25, 2006 u could use time and date. You can do anything like this:1. Save the time/form information in a session.2. Save the time/form information in your database.the first option would probably be easier. On your form page just have it first try to find the session. If it finds the session and the time was more than 5 minutes ago, erase session and start over. If not, show the info. If there is no session, then create one and show the form with the information. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.