Skip to content

Commit

Permalink
20230822更新。较多修改,为新的授权方式进行准备工作。
Browse files Browse the repository at this point in the history
  • Loading branch information
lclichen committed Aug 22, 2023
1 parent 4946ca7 commit 9c5c1d6
Show file tree
Hide file tree
Showing 9 changed files with 316 additions and 128 deletions.
3 changes: 2 additions & 1 deletion checkToken.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
$con = pdo_database();
//echo($token);
if($token){
// 由于微信小程序的改版,此处需要增加一个变量,用于记录用户是否已经填写了个人信息
$sql = 'SELECT openid,nickName FROM `userinfo` WHERE login_token = :token';
$sth = $con->prepare($sql, array(PDO::ATTR_CURSOR => PDO::CURSOR_FWDONLY));
$sth->execute(array(':token' => $token));
Expand All @@ -24,7 +25,7 @@
else{
die('{"code":1001,"msg":"Token未传入!"}');
}
//echo($ctrl);
//echo($identity);
if($openid){
$redata['code'] = 10;
echo json_encode($redata,JSON_UNESCAPED_UNICODE);
Expand Down
Loading

0 comments on commit 9c5c1d6

Please sign in to comment.