The problem in that thread is quite similiar to what i'm facing, but I still can't figure out the issue i'm having.
I made this small 2-page test to see if I could get sessions to work listed per below:
First page:
Code: Select all
<?php
//show all php errors associated with this page
error_reporting(E_ALL);
ini_set('display_errors', '1');
session_save_path("/home/users/web/b560/as.innovati/public_html/cgi-bin/tmp");
session_start();
$_SESSION['color'] = "red";
$_SESSION['name'] = "Brosef";
$_SESSION['ID'] = "4";
if (isset($_POST['submit']))
{
header('Location: http://www.' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['PHP_SELF']) . '/test2.php');
}
?>
<html>
<head>
<title>test variable sessions pass</title>
</head>
<body>
<form name="form1" action="./test.php" method="post">
<input type="submit" name="submit" value="next page" >
</form>
</body>
</html>Code: Select all
<?php
session_save_path("/home/users/web/b560/as.innovati/public_html/cgi-bin/tmp");
session_start();
//show all php errors associated with this page
error_reporting(E_ALL);
ini_set('display_errors', '1');
echo $_SESSION['color'];
echo $_SESSION['name'];
echo $_SESSION['ID'];
print_r($_SESSION);
?>Code: Select all
Warning: session_start() [function.session-start]: open(/home/users/web/b560/as.innovati/public_html/cgi-bin/tmp/sess_8ff8c1807f3d1fc5735cb139d1bfcfdb, O_RDWR) failed: No such file or directory (2) in /hermes/web03/b560/as.innovati/public_html/login/test.php on line 7
Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /hermes/web03/b560/as.innovati/public_html/login/test.php:7) in /hermes/web03/b560/as.innovati/public_html/login/test.php on line 7
Warning: Unknown(): open(/home/users/web/b560/as.innovati/public_html/cgi-bin/tmp/sess_8ff8c1807f3d1fc5735cb139d1bfcfdb, 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 (/home/users/web/b560/as.innovati/public_html/cgi-bin/tmp) in Unknown on line 0