Re: header() and session issues...

From: Date: Sun, 04 Nov 2001 23:33:17 +0000
Subject: Re: header() and session issues...
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-73426@lists.php.net to get a copy of this message
> index.php > -------------------------------- > <? > session_start(); > include("includes/globals.inc"); > include("includes/functions.inc"); > > if ($style){ I doubt that a session_start() would be enough to access $style in the global scope. Consider register_globals ini directive, for example... Instead: if(!isset($HTTP_SESSION_VARS['style'])) > bc_header("search", $style); > } > else{ > bc_header("search", $style2); > } > > print("<a href=./setstyle.php?color=./css/bc_1.css><img src=./images/color1.jpg > border=0></a>"); > > ?> > > > setstyle.php > ------------------------------- > <? > session_start(); > session_register('style'); > $style=$color; > > header ("location: $HTTP_REFERER"); //goes back to index.php > ?> > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net >

« previous php.general (#73426) next »