bljepp69 Posted November 30, 2006 Share Posted November 30, 2006 Try this at the top of your page. This will show you what session variables there are and what their values are:[code]<?phpsession_start();include_once'includes/header.php';include_once'includes/db.php';echo "SESSION:<pre>".print_r($_SESSION,TRUE)."</pre>";?>[/code]Then you will at least know for sure that the session variables are there. Link to comment https://forums.phpfreaks.com/topic/28952-header-problem/page/2/#findComment-132968 Share on other sites More sharing options...
corillo181 Posted November 30, 2006 Author Share Posted November 30, 2006 i get thisSESSION:Array()what i did was take the redirect and see if the session works on the page and it does.. the session just breakes as soon as i click to another page.. Link to comment https://forums.phpfreaks.com/topic/28952-header-problem/page/2/#findComment-132973 Share on other sites More sharing options...
bljepp69 Posted November 30, 2006 Share Posted November 30, 2006 Is there something in your "header.php" include file that could be causing an issue with the session? The output you show above means that your $_SESSION variable is empty. Move the 'echo...' line above the includes, and try it again. Link to comment https://forums.phpfreaks.com/topic/28952-header-problem/page/2/#findComment-132980 Share on other sites More sharing options...
corillo181 Posted November 30, 2006 Author Share Posted November 30, 2006 same effect... whats wrong.. i thought session_start carries the session that has been stared around..plus my header.php is base of html i dont evne know why i named it .php ther eis nothing in there that would mess any code.. Link to comment https://forums.phpfreaks.com/topic/28952-header-problem/page/2/#findComment-132985 Share on other sites More sharing options...
corillo181 Posted December 1, 2006 Author Share Posted December 1, 2006 oh i tihnk i found the problem it just came to me after all t his time.. when a websit eis hosting, you need a folder so it can contian the sessions..damn i feel so stupid.. :( Link to comment https://forums.phpfreaks.com/topic/28952-header-problem/page/2/#findComment-133119 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.