RE: [PHP] Session output question

From: Date: Wed, 22 Oct 2003 17:56:03 +0000
Subject: RE: [PHP] Session output question
Groups: php.general 
Request: Send a blank email to php-general+get-167131@lists.php.net to get a copy of this message
Perfect. Thank you so much. That was exactly what I needed. Susan -----Original Message----- From: CPT John W. Holmes [mailto:holmes072000@charter.net] Sent: Wednesday, October 22, 2003 1:53 PM To: Susan Ator; php-general@lists.php.net Subject: Re: [PHP] Session output question From: "Susan Ator" <SAtor@npr.org> > 1) Is there any way to print out active sessions names? > > I have $_SESSION['SID'], $_SESSION['uid'], $_SESSION['msg'] > can I output the literal strings: > $_SESSION['SID'] > $_SESSION['uid'] > $_SESSION['msg'] $keys = array_keys($_SESSION); > 2) Is there any way to use a variable in a session name? > > can I do: > $msg="20031022" > $_SESSION["$msg.name"] becomes $_SESSION['20031022name'] Just like that or $_SESSION[$msg.'name']. Same rules as making a string anywhere else; that's all you're doing. ---John Holmes... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

« previous php.general (#167131) next »