Re: Re[2]: [PHP] Lost session variables still confounding me
| From: | Stuart Felenstein | Date: | Thu, 04 Nov 2004 10:20:04 +0000 |
| Subject: | Re: Re[2]: [PHP] Lost session variables still confounding me | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-201145@lists.php.net to get a copy of this message | ||
--- Richard Davey <rich@launchcode.co.uk> wrote:
> Before setting the session value in Page 2, check
> for the existence of
> the $_POST value first.
>
> if (isset($_POST['var']))
> {
> $_SESSION['var'] = $_POST['var'];
> }
>
> When you now redirect to Page 2 upon an error, it'll
> skip this block
> because the $_POST var won't exist.
>
I'm a bit confused, this fixes the problem ?
Stuart