using cookies and flash problem

From: Date: Sun, 12 May 2002 19:56:22 +0000
Subject: using cookies and flash problem
Groups: php.general 
Request: Send a blank email to php-general+get-97258@lists.php.net to get a copy of this message
I'm having a problem with using cookies and flash, I'm new to php so it's more then likely my coding, I have a forum made from flash/php/mysql, and I'm trying to use cookies for the username and password so they dont have to log in, I have manage to create the cookies no problem, its the rest thats wrong, I'll post the code to read the cookies: <? $time = (time() + 3600 * 24 * 30 * 12); $cookiepath = "/"; $cookiedomain = "www.deadsam.com"; $cookiesecure = false; setcookie("username", $username, $time, $cookiepath, $cookiedomain, $cookiesecure); setcookie("password", $password, $time, $cookiepath, $cookiedomain, $cookiesecure); //get number of set cookies $cookieCount = count($HTTP_COOKIE_VARS); //if more than 1 cookie if ($cookieCount > 0) { //Loop through all the cookies... foreach($HTTP_COOKIE_VARS as $cookieName => $cookieValue){ //output name and value print "$cookiename=$cookieValue&"; } } else { //otherwise out no cookies print "&userStatus=you are not logged in"; } ?> In flash I used a loadVariableNum("http://www.deadsam.com/cookiescript.php", this, "POST"); I keep getting errors with this. If anyone has an answer to this I'd appreciate it very much. Thank you in advance Deadsam

« previous php.general (#97258) next »