Kevin M Posted May 26, 2007 Share Posted May 26, 2007 Quick Session Question.Say on a page, I have this code: if (!isset($_SESSION['user'])) {header('location: index.php');exit;} Will I need to have the session_start() function at the top of the page, even if I'm not echo'ing out or creating/modifying any session data? Or is the session_start() function needed on every page where you use sessions at all?Thanks,Kevin Link to comment Share on other sites More sharing options...
zppblood Posted May 26, 2007 Share Posted May 26, 2007 Yes. Link to comment Share on other sites More sharing options...
Kevin M Posted May 26, 2007 Author Share Posted May 26, 2007 Ok, thanks I appreciate it. Link to comment Share on other sites More sharing options...
justsomeguy Posted May 29, 2007 Share Posted May 29, 2007 Quick Session Question.Say on a page, I have this code:"on a page, I have this code" Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.