Page 1 of 1

how can i expire the submitted page using session.

Posted: Fri Oct 30, 2009 11:51 am
by awdhut
hi,
i'm new to php world.
i'm using "post" method.
when i submit it,data goes to database successfully.
BUT when i click the back button of browser(IE) the previous
page will appear.
how can i expire the submitted page using session.
please send the code.

Re: how can i expire the submitted page using session.

Posted: Fri Oct 30, 2009 12:06 pm
by McInfo
When the form page is requested, check for the existence of a session variable (like $_SESSION['HasBeenSubmitted']). If the flag (variable) is not set, display the page. If the flag is set, do something else. Set the flag (assign it a value) when processing the submitted form data.

Edit: This post was recovered from search engine cache.

Re: how can i expire the submitted page using session.

Posted: Sat Oct 31, 2009 3:10 am
by awdhut
Thanks sir,
I have done it.
Thank you very much.