请问token验证失败是哪里的问题
代码如下:
$timestamp = $_GET['timestamp'];
$nonce = $_GET['nonce'];
$token = 'xiexie';
$signature = $_GET['signature'];
$array = ();
$array = $array($timestamp,$nonce,$token);
sort($array);
$tmpstr = implode('',$array);
$tmpstr = sha1($tmpstr);
if($tmpstr == $signature){
echo $_GET['echostr'];
exit;
}
$array = $array($timestamp,$nonce,$token);
应该写成
$array = array($timestamp,$nonce,$token);
第二个array多了一个$符号