Trouble Setting Cookies
gregory.lypny at videotron.ca
Thu Aug 12 15:59:22 CDT 2010
Having trouble setting my first cookies at On-Rev. My iRev script pulls in a page template and puts it into a variable called thePage. thePage starts with the usual stuff, such as
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
My feeble understanding of setting cookies is that I must send off the request before I load the page, so I created a simple cookie like this
put "myCookie=" into theCookie
put 6666 after theCookie
I then sent if off with
put new header ("Set-Cookie:" && theCookie)
and then immediately followed with
But the cookie does not appear in Safari's cookie listing or by checking $_SERVER["HTTP_COOKIE"]. The latter, however, gives me two cookies set by .revolutionss.com, which presumably has something to do with my On-Rev account.
I also tried Andre Garzia's function
but struck out there too. What am I doing wrong?
More information about the use-livecode