cookie Usage Let's take a look at the PHP cookie usage today and give a simple example to illustrate. Cookies I don't want to say that most will understand that it just saved a cookie file on the client, read it in a browser, Well, the rest is not much to say. Want to know more please go to www.111cn.cn to find it.
$value =$_server[' Http_host '];
Echo $value;
if (Empty ($_cookie["Cook"])) {
Setcookie ("Cook", $value, Time () +1800, "/");
if (sizeof ($_post) <8) {echo ' BB ';}
for ($i =1; $i <=8; $i + +) {
$c =$_post[' R '. $i];
Switch (intval ($c)) {
Case 0:
$word = ' vote_r1 ';
Break
Case 1:
$word = ' vote_r2 ';
Break
Case 2:
$word = ' VOTE_R3 ';
Break
Default
Exit (' Error ');
}
$sql = "Update gx_votes set $word = $word +1 where id= $i";
mysql_query ($sql) or Die (Mysql_error ());
}
echo ' OS ';
}else{
print ' 00 ';
}
Note: The original site reproduced please specify www.111cn.cn
http://www.bkjia.com/PHPjc/631374.html www.bkjia.com true http://www.bkjia.com/PHPjc/631374.html techarticle cookie Usage Let's take a look at PHP cookie usage today and give a simple example to illustrate. Cookies I would not say that most will understand that it just saved a cookie file on the client ...