| 123456789101112131415161718192021222324252627282930313233343536373839404142 | <?phpnamespace Home\Controller;use Think\Model;/** * 首页 * @author   Devil * @blog     http://gong.gg/ * @version  0.0.1 * @datetime 2016-12-01T21:51:08+0800 */class OrderController extends CommonController {    /**     * 鉴权接口     */    public function contentCTCAuth() {        error_reporting(0);        $map['userid'] = I('uid');        $map['contentcode'] = I('contentcode');        $map['usertoken'] = I('usertoken');        $map['version'] = I('version');        $map['mac'] = I('mac');        $map['fromsource'] = 15;        $prame = http_build_query($map);        //$url = 'http://183.215.118.129:6600/SPM/Interface/ContentCmccAuth.action?' . $prame;        $url = 'http://10.2.219.176:6600/SPM/Interface/ContentCmccAuth.action?' . $prame;        // \Think\Log::record('-------contentCTCAuth url------' . $url, \Think\Log::INFO); //记录参数        $result = $this->http($url);        Writelog(json_encode($result,JSON_UNESCAPED_UNICODE|JSON_UNESCAPED_SLASHES),$url,'activityv2');        if ($result[0] != 200) {            $this->responseError('接口请求失败');        }        // \Think\Log::record('-------contentCTCAuth result------' . $result[1], \Think\Log::INFO); //记录参数        $result = json_decode($result[1]);//        $result = '{"Message":"","Result":0,"count":0,"week":0}';        $data['result'] = $result->Result;        $this->responseSuccess($data, '查询成功!');    }}
 |