PHP-ban SESSION-t szeretnék létrehozni, de mindig valami könyvtárra hivatkozik, ötlet?
Ezt kapom vissza (atw-s a tárhely):
Warning: session_start() [function.session-start]: open(/tmp/sess_366ed3ec254c52bbf80f18ad491e16f5, O_RDWR) failed: No such file or directory (2) in /index.php on line 2
Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at /index.php:2) in /index.php on line 2
Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /index.php:2) in /index.php on line 2
Warning: Unknown: open(/tmp/sess_366ed3ec254c52bbf80f18ad491e16f5, O_RDWR) failed: No such file or directory (2) 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 (/tmp) in Unknown on line 0
Forrás:
include("connect.php");
if(isset($_POST["login_submit"])) {
$myusername=$_POST["user_login"];
$mypassword=$_POST["user_pass"];
$myusername = stripslashes($myusername);
$mypassword = stripslashes($mypassword);
$myusername = mysql_real_escape_string($myusername);
$mypassword = mysql_real_escape_string($mypassword);
$sql="SELECT * FROM user_login WHERE username='$myusername' and userpass='$mypassword'";
$result=mysql_query($sql);
$count=mysql_num_rows($result);
if($count==1){
$_SESSION["user_session"] = $myusername;
session_register("login_username");
}
else {
}
}
Ja és ha a session_start()-ot meghívom akkor ezt írja ki (a többi mellé):
Warning: session_start() [function.session-start]: open(/tmp/sess_3d2cb0d29e482d8fc36b67963f01ed22, O_RDWR) failed: No such file or directory (2) in /index.php on line 2
Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /index.php:2) in /index.php on line 2
Kapcsolódó kérdések:
Minden jog fenntartva © 2024, www.gyakorikerdesek.hu
GYIK | Szabályzat | Jogi nyilatkozat | Adatvédelem | Cookie beállítások | WebMinute Kft. | Facebook | Kapcsolat: info(kukac)gyakorikerdesek.hu
Ha kifogással szeretne élni valamely tartalommal kapcsolatban, kérjük jelezze e-mailes elérhetőségünkön!