note 22762 deleted from function.setcookie by dams

From: Date: Sat, 29 Jun 2002 00:27:15 +0000
Subject: note 22762 deleted from function.setcookie by dams
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-32392@lists.php.net to get a copy of this message
ok if u need to save two cookies i have writen some stupied but it works... cook.php <? global $HTTP_COOKIE_VARS; setcookie($cName, $cValue,time()+3601,"/","", 0); ?> <script language="JavaScript1.2"> window.close(); </script> and where u want to call it from... <script language="JavaScript1.2"> function cooky(n,v) { c=window.open("cook.php?cName="+n+"&cValue="+v,"cook"+n); } cooky("cookName0","cookValue1"); cooky("cookName1","cookvalue2"); </script>

« previous php.notes (#32392) next »