123456789101112131415161718 |
-
- <?php
- //scope=snsapi_userinfo实例
- $appid=$_GET["appid"];
- $zfopenid = $_GET["zfopenid"];
- $kfopenid = $_GET["kfopenid"];
- $toUsername = $_GET["toUsername"];
- $json = file_get_contents('json/'.$toUsername.'.json');
- //echo $json;
- $arr = json_decode($json,true);
- $website=$arr['website'];
- $kfname = $_GET["kfname"];
- $redirect_uri = urlencode ("$website/addons/qidong_app/project.php?zfopenid=$zfopenid&toUsername=$toUsername&kfopenid=$kfopenid&kfname=$kfname" );
- //echo $redirect_uri;
- //exit;
- $url ="https://open.weixin.qq.com/connect/oauth2/authorize?appid=$appid&redirect_uri=$redirect_uri&response_type=code&scope=snsapi_userinfo&state=1#wechat_redirect";
- header("Location:".$url);
- ?>
|