I am looking for a "readcookie" function to compliment the "setcookie", but I do not suppose such a function exists. As it stands, I am trying to use the $_COOKIE. My ultimate goal is to simply write a string on one page, and read it on another.
My set code:
$name = "k";
$expire = NULL;
$path = "/";
$domain = $_SERVER['HTTP_HOST'];
$secure = 0;
setcookie($name, $value, $expire, $path, $domain, $secure);
My get code:
$value = $_COOKIE['k'];
This generates the error: "Notice: Undefined index: k in c:\inetpub\wwwroot\ecrg-reg\cget.php on line 4"
Any suggestions on what I am missing? Thanks in advance,
J Wolfgang Goerlich