* "Alessandro Rosa" <zandor_zz@xxxxxxxx>: > Hi to all, > > I got a problem while storing session variables. > > <?php > session_start(); > header( "Cache-control: private" ); > > require_once("config.inc.php"); > > //////////////////////////////////////////////////////////// > $_SESSION['session_psw'] = $_POST['txtPassword']; > $_SESSION['session_user'] = $_POST['txtIdUtente']; > > //////////////////////////////////////////////////////////// > > $PHPcmd = $GLOBALS['gestionale_path_name']."test/2.php" ; > > header( "Location: ".$PHPcmd ); > > ?> > > After the call to header(...), the values of session variables are lost. Does config.inc.php have any whitespace following the closing ?> tag, or does it output any HTML? That could be your culprit. What happens if you do your $_SESSION setting *before* the require, but directly after the initial header() call? -- Matthew Weier O'Phinney | WEBSITES: Webmaster and IT Specialist | http://www.garden.org National Gardening Association | http://www.kidsgardening.com 802-863-5251 x156 | http://nationalgardenmonth.org mailto:matthew@xxxxxxxxxx | http://vermontbotanical.org -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php