I'm being pretty dense, methinks, but I can find no way to show the sessionid that is automatically created and stored in a cookie on my PHP4/Apache module setup. Session ID's are being stored in my /tmp directory (I can see them with an ls there)
I want to be able to store this in a database as part of a shopping cart script in place of UserID (MyCart.php)
If I could get it into a variable I can manipulate, I can go from there, but I can't even look at it....
I've tried a number of things:
print_r($sid);
echo "SID $SID";
echo "PHPSESSIONID $PHPSESSID";
echo "SessionID $session_id()";
echo "Session_id $session_id";
$co=session_get_cookie_params();
print_r($co);
$tsid=session_id();
print_r($tsid);
$testarray=getenv($HTTP_COOKIE_VARS);
var_dump(testarray);
$a=getenv("HTTP_SERVER_VAR");
print_r($a);
$p=getenv("HTTP_COOKIE");
print_r($p);
$ip = getenv("REMOTE_ADDR");
print_r($ip);
?>