Re: $_POST- Vars -> Back-Button

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hey Chris,

1) Use sessions (read up on it if you don't know it; in short: session_start() at the very beginning of your script creates a $_SESSION array that is persistent through subsequent page calls) 2) Submit the form to the search page and preprocess it by putting the post vars into the session, then use header() to relocate to the actual processor 3) Have the actual processor work, i.e. the result list page script, with the session data. Do not destroy the session data afterwards.

Now if a user uses the back-button from your result list, he will again reach the search page, without the 'wanna send form again' message box. I very strongly advise you not to break the browsers back button functionality. It's there for a reason and people rely on it to behave accordingly. Don't duplicate functionality that the browser already has.

HTH,

Stijn

Christian Hänsel schreef:
Hi guys,

this might be a noob- question, but I simply do not care anymore. After a few hours of fiddling with this @/**&%$ (screaming "AAaaaaahhhh"), I would like to ask you.

So what I have is this: I have a search engine for a car market, which has about 30 $_POST- vars. Now when the user clicks on a result link, it takes him to the car details page. Now when he hits the back button, he either gets the "Page has expired" (IE) or the "Wanna send the form data again" message box (FF).

Now I would like to have kind of a "back-button", so the user will see the reusult list again without having to deal with this.

I guess what I'm asking for is a one-click re-submission of POST data... Do you have a clue on how to do this?

Cheers for any answers!

Chris


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux