creativkook Posted February 13, 2007 Share Posted February 13, 2007 Ok, I'm having problems with my session starting and recognizing it. This is from the login page, and it's not letting it send to the next page. Here are the errors I'm getting: Warning: session_start(): open(C:\PHP\sessiondata\sess_ef565a18d6c2e623e74300375c5613d8, O_RDWR) failed: Permission denied (13) in C:\Web\Plaid\index.php on line 20 Warning: session_start(): Cannot send session cookie - headers already sent by (output started at C:\Web\Plaid\index.php:20) in C:\Web\Plaid\index.php on line 20 Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at C:\Web\Plaid\index.php:20) in C:\Web\Plaid\index.php on line 20 Warning: Cannot modify header information - headers already sent by (output started at C:\Web\Plaid\index.php:20) in C:\Web\Plaid\index.php on line 24 Warning: Unknown(): open(C:\PHP\sessiondata\sess_ef565a18d6c2e623e74300375c5613d8, O_RDWR) failed: Permission denied (13) in Unknown on line 0 Warning: Unknown(): Failed to write session data (files). Please verify that the current setting of session.save_path is correct (C:\PHP\sessiondata) in Unknown on line 0 Here's the session start code: if(isset($_POST['login'])) { $user = $_POST['user']; $pass = $_POST['password']; require("dbheader.php"); $person = mysql_query("SELECT userID FROM plaidusers WHERE username = '$user' AND password = MD5('$pass')"); if(mysql_num_rows($person) > 0) { $persons = mysql_fetch_array($person); session_start(); $_SESSION['userID'] = $persons['userID']; header("location: home.php?userid=$person[userID]"); exit; } else { $error = true; } } Quote Link to comment https://forums.phpfreaks.com/topic/38347-sessions-problems/ Share on other sites More sharing options...
Caesar Posted February 13, 2007 Share Posted February 13, 2007 Make sure you have write permissions to write the sessions to the server. P.S...Avoid using Windows servers. They stink. Quote Link to comment https://forums.phpfreaks.com/topic/38347-sessions-problems/#findComment-183803 Share on other sites More sharing options...
Jessica Posted February 13, 2007 Share Posted February 13, 2007 Read the stickied topic about header errors. This has nothing to do with permissions or Windows. Quote Link to comment https://forums.phpfreaks.com/topic/38347-sessions-problems/#findComment-183804 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.