1.easywechat安装

 wechat开发

 

 2.weichat打通服务器

    function  getTest(Request $request){
        $token = 'zhenhaokeji';
        $data = $request->all();
        $signature = $data['signature'];
        $timestamp = $data['timestamp'];
        $nonce = $data['nonce'];
        $echostr = $data['echostr'];
        $arrtep = array($token, $timestamp, $nonce);
        sort($arrtep, SORT_STRING);
        $arrStr = implode($arrtep);
        $hashcode = sha1($arrStr);
        if($hashcode == $signature){
            return $echostr;
        }else{
            return false;
        }

    }

 

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-07-18
  • 2021-05-26
  • 2021-09-14
  • 2022-02-04
  • 2022-12-23
  • 2021-12-08
相关资源
相似解决方案