添加后台代理代码
This commit is contained in:
BIN
codes/agent/game/dlweb/api/document/platform.rar
Normal file
BIN
codes/agent/game/dlweb/api/document/platform.rar
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/web.zip
Normal file
BIN
codes/agent/game/dlweb/api/document/web.zip
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/个人代理前端页面与服务器的接口.xlsx
Normal file
BIN
codes/agent/game/dlweb/api/document/个人代理前端页面与服务器的接口.xlsx
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/代理后台2.0开发计划.xlsx
Normal file
BIN
codes/agent/game/dlweb/api/document/代理后台2.0开发计划.xlsx
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/代理后台接口文档.xlsx
Normal file
BIN
codes/agent/game/dlweb/api/document/代理后台接口文档.xlsx
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/代理后台数据库表定义.docx
Normal file
BIN
codes/agent/game/dlweb/api/document/代理后台数据库表定义.docx
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/代理结算系统开发进度表.xlsx
Normal file
BIN
codes/agent/game/dlweb/api/document/代理结算系统开发进度表.xlsx
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/友乐渠道支付对接文档.xlsx
Normal file
BIN
codes/agent/game/dlweb/api/document/友乐渠道支付对接文档.xlsx
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/友乐牛牛代理后台业务.rar
Normal file
BIN
codes/agent/game/dlweb/api/document/友乐牛牛代理后台业务.rar
Normal file
Binary file not shown.
46
codes/agent/game/dlweb/api/document/微信开发判断用户是否已关注公众号.txt
Normal file
46
codes/agent/game/dlweb/api/document/微信开发判断用户是否已关注公众号.txt
Normal file
@@ -0,0 +1,46 @@
|
||||
在做微信开发时有时需要判断用户是否已关注公众号,以便于做出不同的回应,如提醒用户关注公众号等。
|
||||
|
||||
判断用户是否已关注公众号可能通过获取用户信息来操作。
|
||||
|
||||
如果已关注公众号,那么微信返回的JSON数据包会包含”subscribe”: 1这样的信息。
|
||||
如果未关注公众号,那么微信返回的JSON数据包会包含”subscribe”: 0这样的信息。
|
||||
开发者可通过OpenID到http GET请求方式调用接口来获取用户基本信息。
|
||||
|
||||
请求示例:
|
||||
|
||||
https://api.weixin.qq.com/cgi-bin/user/info?access_token=ACCESS_TOKEN&openid=OPENID&lang=zh_CN
|
||||
参数:
|
||||
|
||||
参数 是否必须 说明
|
||||
access_token 是 调用接口凭证
|
||||
openid 是 普通用户的标识,对当前公众号唯一
|
||||
lang 否 返回国家地区语言版本,zh_CN 简体,zh_TW 繁体,en 英语
|
||||
以下是PHP来判断用户是否已关注公众号的示例
|
||||
|
||||
function verification($openid,$accestoken){
|
||||
|
||||
$url = 'https://api.weixin.qq.com/cgi-bin/user/info?access_token='.$accestoken.'&openid='.$openid.'&lang=zh_CN';
|
||||
$json_Wxuser=json_decode(curlGet($url),true);
|
||||
//获取用户信息后,判断subcribe == 0 那么就是未关注
|
||||
if(isset($json_Wxuser['subscribe']) && $json_Wxuser['subscribe'] == 0){
|
||||
//跳转到提示用户关注页面中
|
||||
$this->redirect('Guanzhu/index', array('id' => $id), 0, '页面跳转中...');
|
||||
}
|
||||
}
|
||||
|
||||
function curlGet($url){
|
||||
$ch = curl_init();
|
||||
$header = "Accept-Charset: utf-8";
|
||||
curl_setopt($ch, CURLOPT_URL, $url);
|
||||
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "GET");
|
||||
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE);
|
||||
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, FALSE);
|
||||
curl_setopt($curl, CURLOPT_HTTPHEADER, $header);
|
||||
curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/5.0 (compatible; MSIE 5.01; Windows NT 5.0)');
|
||||
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
|
||||
curl_setopt($ch, CURLOPT_AUTOREFERER, 1);
|
||||
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
|
||||
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
|
||||
$temp = curl_exec($ch);
|
||||
return $temp;
|
||||
}
|
||||
BIN
codes/agent/game/dlweb/api/document/接口说明文档.docx
Normal file
BIN
codes/agent/game/dlweb/api/document/接口说明文档.docx
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/操作日志表.xlsx
Normal file
BIN
codes/agent/game/dlweb/api/document/操作日志表.xlsx
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/棋牌运营统计报表指标.xlsx
Normal file
BIN
codes/agent/game/dlweb/api/document/棋牌运营统计报表指标.xlsx
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/渠道代理情况.xlsx
Normal file
BIN
codes/agent/game/dlweb/api/document/渠道代理情况.xlsx
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/渠道营收数据(新模板)(3)(1).xlsx
Normal file
BIN
codes/agent/game/dlweb/api/document/渠道营收数据(新模板)(3)(1).xlsx
Normal file
Binary file not shown.
18
codes/agent/game/dlweb/api/document/红包接口.txt
Normal file
18
codes/agent/game/dlweb/api/document/红包接口.txt
Normal file
@@ -0,0 +1,18 @@
|
||||
红包接口:
|
||||
请求地址:https://api.tscce.cn/api/newpay/sendredpack
|
||||
请求类型:post
|
||||
请求参数:
|
||||
appid: appid
|
||||
devkey: 开发者key
|
||||
sid: 登录sid
|
||||
scode: scode
|
||||
orderid: 订单号
|
||||
fee: 红包金额(单位分,1元起步)
|
||||
wishing: 红包祝福语
|
||||
act_name: 活动名称
|
||||
remark: 备注
|
||||
send_type: 红包类型(1;微信;2:支付宝)
|
||||
version: 版本号(1)
|
||||
|
||||
|
||||
https://api.tscce.cn/api/newpay/sendredpack?appid=14936872341446&devkey=14915485974028&sid=YzT0CfCcZgqQV1dG0dZ77GR17d1R1Dqf&scode=005e15ed67176af569d6a170ef3981fa&orderid=1&fee=100&wishing=红包祝福语&act_name=活动名称&remark=备注&send_type=1&version=1
|
||||
BIN
codes/agent/game/dlweb/api/document/统计报表.pptx
Normal file
BIN
codes/agent/game/dlweb/api/document/统计报表.pptx
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/袋鼠分成后台.xlsx
Normal file
BIN
codes/agent/game/dlweb/api/document/袋鼠分成后台.xlsx
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/袋鼠分成后台(第一版).pptx
Normal file
BIN
codes/agent/game/dlweb/api/document/袋鼠分成后台(第一版).pptx
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/运营后台计划.xlsx
Normal file
BIN
codes/agent/game/dlweb/api/document/运营后台计划.xlsx
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/运营后台进度.xlsx
Normal file
BIN
codes/agent/game/dlweb/api/document/运营后台进度.xlsx
Normal file
Binary file not shown.
BIN
codes/agent/game/dlweb/api/document/运营报表设计.xlsx
Normal file
BIN
codes/agent/game/dlweb/api/document/运营报表设计.xlsx
Normal file
Binary file not shown.
Reference in New Issue
Block a user