[thelist] any PHP session experts out there?

Tom Dell'Aringa pixelmech at yahoo.com
Thu Dec 12 09:36:04 CST 2002

--- Carl J Meyer <cjmeyer at npcc.net> wrote:

> Also, your call to session_register is unnecessary - adding an
> entry to
> the $_SESSION array is all you need to do to register the session
> value.  In fact, the PHP manual specifically warns against trying
> to use
> both session_register() and the $_SESSION array, so conceivably
> taking
> out the call to session_register() could fix your problem.

Thanks for all the help! I have it working now and I am using both
$_SESSION and $_POST, which does indeed make sense in light of
everything everyone posted.

2 Quick questions:

1) I figured using the querystring would be $_QUERYSTRING or
something, but I can't find that...how do I grab the query string
vars the 'safe' way

2) I tried using this code on my user registration page to destroy
the current session so the user could start a new one if they wanted
to.. not sure its necessary (I guess they wouldn't re-register) but I
wondered why the code didn't work:

$_SESSION = array();

I got the error:
Warning: Trying to destroy uninitialized session

I currently have a session running (I know its working, the name pops
up on each page)



var me = tom.pixelmech.webDeveloper();

[Making A Commercial Case for Adopting Web Standards]

Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.

More information about the thelist mailing list