Call us Toll-Free:
1-800-218-1525
Live ChatEmail us

 Sponsors

php cookie

Code Wizard, 12-30-2006

this script will save a cookie on the remote host..very simpel!

ofcourse the user that visits your site must have cookies enabled for this "example" to work.

<?
if (!isset($id)) {
srand((double)microtime()*1000000);
$val_of_rand = rand();
setcookie("id",$val_of_rand,time()+14400,"/",".csoft.net/~syssoft",0);
}
?>
Enjoyed this post?

Subscribe Now to receive new posts via Email as soon as they come out.

 Comments
Post your comments












Note: No link spamming! If your message contains link/s, it will NOT be published on the site before manually approved by one of our moderators.



About Us  |  Contact us  |  Privacy Policy  |  Terms & Conditions