我在PHP中有脚本:
<?php
$secretkey='1kaSutSkaDstekSko345QQeVa3ratko1aAKSU2stIHFH44fheo1FhHEfo2oe6fifhkhs';
$parray = array($tagId, $userId);
$validate = serialize($parray);
$key=md5($validate.$secretkey);
?>
<a href="delfollow.php?tagid=<?php echo $tagId ?>&userid=<?php echo $userId ?>&key=<?php echo $key ?>">Delete</a>
在delfollow.php中:
$userId = $_GET['userid'];
$tagId = $_GET['tagid'];
$key = $_GET['key'];
$secretkey='1kaSutSkaDstekSko345QQeVa3ratko1aAKSU2stIHFH44fheo1FhHEfo2oe6fifhkhs';
$parray = array($tagId, $userId);
$validate = serialize($parray);
$nkey=md5($validate.$secretkey);
echo $key."<br/>";
echo $nkey."<br/>";
这把钥匙是不同的!这是为什么。
答案 0 :(得分:0)