RE: Validation and session variables

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

 



See in-line comments...

> -----Original Message-----
> From: Stuart Felenstein [mailto:stuart4m@xxxxxxxxx]
> Sent: 28 October 2004 08:54
> To: php-general@xxxxxxxxxxxxx
> Subject:  Validation and session variables
>
>
> I guess my resolution was a fluke.
> Recap: Adding validation kills my session variables
> Now I tested a few things, SID is consistent across
> pages, so a new sid and cookie are not being
> generated.
>
> Perhaps it's a bug, Im on PHP 4.3.8
>
> Here is the code again, perhaps something will jump
> out.
>
> <?php
>
> //Start the Session - begin Block
> @session_start();
> header("Cache-control: private");
[snip]
>
>   if ($WAFV_Errors != "")  {
>     PostResult($WAFV_Redirect,$WAFV_Errors,"page1");
>   }

I think we need to know what happens when this function returns the user to
the script upon finding an error. Are all the form field values passed back?
Does it do anything at all with the session? Does it pass the SID?

> }
> ?>
> <?php
>
>
> if ($_SERVER["REQUEST_METHOD"] == "POST") {
> Header ('Location:
> http://www.xxxxxx.com/page2.php?'.SID);
>
> }
> ?>
>
> I just set an echo on page2 and page3 of the first
> session variable 'listingname'.  If I have the
> validation code in page1 , it doesn't even make it to
> page2

Are you saying that page1 always fails validation even if you enter all the
form fields correctly? If so then something is most likely wrong with the
validation code. Double check all the validation steps.


Graham

-- 
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