Guten Tag,
ich will Session übergeben, und auf jeder Seite bekomme ich den neuen session_id(). Die Problem liegt bestimmt daran, dass der Browser keine Cookies zurückliefert. Also unten steht Code
____________________________________
index.php
<?php
session_start();
$_SESSION['ses_login'] = $_POST['login'];
print(session_id());
?>
<a href="start.php">Link</a>
____________________________________
____________________________________
start.php
<?php
session_start();
print(session_id());
if(isset($_SESSION['ses_login']))
{
print("OK");
}
else
{
print("Session fail");
}
?>
____________________________________
Server Einstellungen:
session
Session Support enabled
Registered save handlers files user
Directive Local Value Master Value
session.auto_start Off Off
session.bug_compat_42 On On
session.bug_compat_warn On On
session.cache_expire 180 180
session.cache_limiter nocache nocache
session.cookie_domain no value no value
session.cookie_lifetime 3600 3600
session.cookie_path no value no value
session.cookie_secure Off Off
session.entropy_file /dev/urandom /dev/urandom
session.entropy_length 16 16
session.gc_divisor 100 100
session.gc_maxlifetime 1200 1200
session.gc_probability 0 0
session.name PHPSESSID PHPSESSID
session.referer_check no value no value
session.save_handler files files
session.save_path 2;/data/session 2;/data/session
session.serialize_handler php php
session.use_cookies On On
session.use_only_cookies Off Off
session.use_trans_sid Off Off
ich will Session übergeben, und auf jeder Seite bekomme ich den neuen session_id(). Die Problem liegt bestimmt daran, dass der Browser keine Cookies zurückliefert. Also unten steht Code
____________________________________
index.php
<?php
session_start();
$_SESSION['ses_login'] = $_POST['login'];
print(session_id());
?>
<a href="start.php">Link</a>
____________________________________
____________________________________
start.php
<?php
session_start();
print(session_id());
if(isset($_SESSION['ses_login']))
{
print("OK");
}
else
{
print("Session fail");
}
?>
____________________________________
Server Einstellungen:
session
Session Support enabled
Registered save handlers files user
Directive Local Value Master Value
session.auto_start Off Off
session.bug_compat_42 On On
session.bug_compat_warn On On
session.cache_expire 180 180
session.cache_limiter nocache nocache
session.cookie_domain no value no value
session.cookie_lifetime 3600 3600
session.cookie_path no value no value
session.cookie_secure Off Off
session.entropy_file /dev/urandom /dev/urandom
session.entropy_length 16 16
session.gc_divisor 100 100
session.gc_maxlifetime 1200 1200
session.gc_probability 0 0
session.name PHPSESSID PHPSESSID
session.referer_check no value no value
session.save_handler files files
session.save_path 2;/data/session 2;/data/session
session.serialize_handler php php
session.use_cookies On On
session.use_only_cookies Off Off
session.use_trans_sid Off Off
Kommentar