Re: [PHP] help with session

2007-08-31 Thread Dan
You should be sanatizing code here. When you save it to the session and when it's output. Look arround the newsgroups or online for info about it, it's everywhere. - Dan "mike" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] On 8/26/07, Jason Cartledge <[EMAIL PROTECTED]> wrote

Re: [PHP] help with session

2007-08-26 Thread Wouter van Vliet / Interpotential
I would go for: if (isset($_REQUEST['gender'])) $_SESSION['registrationGender'] = $_REQUEST['gender']; print isset($_SESSION['registrationGender']) ? "You are registered as gender: ".$_SESSION['registrationGender'] : "Your gender is unknown"; And make no assumptions about a gender when yo

Re: [PHP] help with session

2007-08-26 Thread mike
On 8/26/07, Jason Cartledge <[EMAIL PROTECTED]> wrote: I would replace $_REQUEST with $_GET or $_POST (as appropriate) > if ( !empty($_REQUEST['gender']) ) > { >$registrationGender=$_REQUEST['gender']; > } > else { Personally I would use if(isset($_SESSIO

Re: [PHP] Help with session needed

2003-03-09 Thread Jack
On Sun, 9 Mar 2003 21:18:33 +0100 "Øystein Håland" <[EMAIL PROTECTED]> wrote: > The problem is the cookie soon reaches the 4 kb limit, so I would like to > achieve the same using session. The trouble is, I don't know how to do. I > would appreciate any help that brings me closer to a solution on t

Re: [PHP] Help with session variables

2002-12-04 Thread Stephen
Instead of register, set it up like a normal variable. Here's an examlple going by your code: Page1. session_start(); $HTTP_SESSION_VARS['step'] = 1; header("Location: page_A.php"); Page A session_start(); $HTTP_SESSION_VARS['step'] = 2; header("Location: page_B.php"); Page B. sessio

Re: [PHP] Help with session variables

2002-12-03 Thread Jason Wong
On Wednesday 04 December 2002 14:12, Manuel Ochoa wrote: > I'm running PHP 4.3 on a Windows .net server with Apache 2. Please look at > the following code as I cannot figure out what I'm doing wrong. > > Page1. > session_start(); > session_register("step"); > $step=1; > header("location: page_A

Re: [PHP] Help with session

2001-02-15 Thread Richard Lynch
I think you want the session_start() and session_register() calls at the top of the script, not buried in your if() statements. -- Visit the Zend Store at http://www.zend.com/store/ Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm Volunteer a little time: http://chatmusic.c