Browse Source

update:url

master
xiaowei 3 years ago
parent
commit
146fe3b15c
  1. 8
      idapi_config.php
  2. 2
      idapi_function.php
  3. 2
      refreshtoken/index.php

8
idapi_config.php

@ -12,6 +12,14 @@ define('API_KEY', 'i7hP48WAcuTrmxfN');
define('API_URL', 'http://testapi');
define('ID_URL', 'https://id');
//正式环境 - 通行证
//define('NEW_API_URL', 'https://fanruanclub.com');
//测试环境 - 通行证
define('NEW_API_URL', 'https://passport.fanruan.com');
//测试环境 - 数字平台
define('DIGIT_API_URL', 'https://testdpapi.fanruan.com');

2
idapi_function.php

@ -101,7 +101,7 @@ function setRefreshToken()
$id_ckuser = id_CKdecrypt($_COOKIE["fr_id_auth"]);
$id_ckuserinfo = $id_ckuser['client'];
$data = '&appid='.$id_ckuserinfo['appid'].'&uid='.$id_ckuserinfo['uid'].'&refresh_token='.$id_ckuser['refresh_token'];
$re_login = CallInterface(DIGIT_API_URL.'/v1/token/refresh/'.$data,'GET');
$re_login = CallInterface(NEW_API_URL.'/v1/token/refresh/'.$data,'GET');
$jsonarr = json_decode($re_login,true);
if($jsonarr['message']=='success'){
$new_json = json_encode($jsonarr['data'],JSON_UNESCAPED_UNICODE);

2
refreshtoken/index.php

@ -12,7 +12,7 @@ if($get_cookie){
$id_ckuser = id_CKdecrypt($get_cookie);
$id_ckuserinfo = $id_ckuser['client'];
$data = '&appid='.$id_ckuserinfo['appid'].'&uid='.$id_ckuserinfo['uid'].'&refresh_token='.$id_ckuser['refresh_token'];
$re_login = CallInterface(DIGIT_API_URL.'/v1/token/refresh/'.$data,'GET');
$re_login = CallInterface(NEW_API_URL.'/v1/token/refresh/'.$data,'GET');
$jsonarr = json_decode($re_login,true);
if($jsonarr['code']==200){

Loading…
Cancel
Save