<?php
include_once '../qiyehao/weixinPHP/WXBizMsgCrypt.php';
$token = "sbao";
$encodingAesKey = "aVeADrhHlb8GBniQXqOFveeyIWdWUHYhpSifqHiCMyD";
$corpId = "---------------------------";
if (isset($_GET['echostr'])) {
$sVerifyMsgSig = ($_GET['msg_signature']);
$sVerifyTimeStamp = ($_GET['timestamp']);
$sVerifyNonce = ($_GET['nonce']);
$sVerifyEchoStr = ($_GET['echostr']);
$sEchoStr = "";
$wxcpt = new WXBizMsgCrypt($token, $encodingAesKey, $corpId);
$errCode = $wxcpt->VerifyURL($sVerifyMsgSig, $sVerifyTimeStamp, $sVerifyNonce, $sVerifyEchoStr, $sEchoStr);
if ($errCode == 0) {
echo $sEchoStr;
} else {
echo (date("Y-m-d H:i:s") . " ERR : " . $errCode);
}
}
?>
include_once '../qiyehao/weixinPHP/WXBizMsgCrypt.php';
下载地址 是:
http://qydev.weixin.qq.com/download/php.zip