Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

<?php goto Tp1T1; ZQBpM: define('BEST_XCXFANSKEFU', 'messikefu_xcxfanskefu'); goto TOYId..

Decoded Output download

<?php 
 goto Tp1T1; ZQBpM: define('BEST_XCXFANSKEFU', 'messikefu_xcxfanskefu'); goto TOYId; zlZKh: define('BEST_CSERVICEGROUP', 'messikefu_cservicegroup'); goto VmR8F; cG0vp: define('BEST_BIAOQIAN', 'messikefu_biaoqian'); goto c28Zz; wFvla: define('BEST_XCXCSERVICE', 'messikefu_xcxcservice'); goto ZQBpM; VmR8F: define('BEST_FANSKEFU', 'messikefu_fanskefu'); goto i25uy; c28Zz: define('BEST_KUAIJIE', 'messikefu_kuaijie'); goto KrBlr; CSFwx: define('BEST_KEFUANDGROUP', 'messikefu_kefuandgroup'); goto cG0vp; hhIXC: define('BEST_CHAT', 'messikefu_chat'); goto yhWot; SVNcK: define('ROOT_PATH', IA_ROOT . '/addons/cy163_customerservice_plugin_p/'); goto M2dOk; KrBlr: define('BEST_XCX', 'messikefu_xcx'); goto wFvla; M2dOk: define('MD_ROOT', '../addons/cy163_customerservice_plugin_p/static'); goto iTKs7; iTKs7: define('MD_ROOT_Z', '../addons/cy163_customerservice/'); goto f7Mlg; yhWot: define('BEST_CSERVICE', 'messikefu_cservice'); goto zlZKh; iV3it: define('BEST_ZIDONGHUIFU', 'messikefu_zdhf'); goto Di985; R4voD: define('BEST_XCXAUTO', 'messikefu_xcxauto'); goto iV3it; TOYId: define('BEST_XCXCHAT', 'messikefu_xcxchat'); goto R4voD; i25uy: define('BEST_PINGJIA', 'messikefu_pingjia'); goto CSFwx; Tp1T1: defined('IN_IA') or exit('Access Denied'); goto SVNcK; f7Mlg: define('NEWSTATIC_ROOT', '../addons/cy163_customerservice/newstatic'); goto hhIXC; Di985: class Cy163_customerservice_plugin_pModuleSite extends WeModuleSite { public function doMobileKefulogin() { include_once ROOT_PATH . 'inc/mobile/kefulogin.php'; } public function doMobileKefucenter() { include_once ROOT_PATH . 'inc/mobile/kefucenter.php'; } public function doMobileFinishjd() { goto qnsFR; byqxt: goto Iz34a; goto fanYq; FuAqu: exit; goto PGs20; wRwtF: $isjd = intval($_GPC['isjd']); goto jPN7Z; B1_GL: $resArr['msg'] = ''; goto nIj_F; q4Ms3: Iz34a: goto JSYzd; XSVu1: if (empty($lastjd)) { goto Yz1ME; } goto X_5Zt; Zo1wC: $resArr['url'] = $this->createMobileUrl('kefucenter', array("isjd" => $isjd)); goto q4Ms3; qnsFR: global $_W, $_GPC; goto V41tY; x4Ieo: $dataupfk['nowjd'] = 0; goto qO_IP; fanYq: Yz1ME: goto Zo1wC; Fx6XW: $dataupkefu['nowjdnum'] = $cservice['nowjdnum'] - 1; goto FaSZ2; PkHnT: $cservice = pdo_fetch('SELECT * FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = {$_W['uniacid']} AND id = {$id}"); goto ryHyX; JSYzd: $resArr['error'] = 0; goto B1_GL; nIj_F: echo json_encode($resArr); goto FuAqu; V41tY: $fkid = intval($_GPC['fkid']); goto x4Ieo; FaSZ2: pdo_update(BEST_CSERVICE, $dataupkefu, array("id" => $cservice['id'])); goto wRwtF; qO_IP: $dataupfk['jdtime'] = 0; goto Gvu3I; Gvu3I: pdo_update(BEST_FANSKEFU, $dataupfk, array("id" => $fkid)); goto Yggk9; jPN7Z: $lastjd = pdo_fetchall('SELECT fansopenid FROM ' . tablename(BEST_FANSKEFU) . " WHERE weid = {$_W['uniacid']} AND kefuopenid = '{$cservice['content']}' AND nowjd = {$isjd} ORDER BY jdtime ASC LIMIT 1"); goto XSVu1; X_5Zt: $resArr['url'] = $this->createMobileUrl('kefucenter', array("toopenid" => $lastjd[0]['fansopenid'], "isjd" => $isjd)); goto byqxt; ryHyX: $dataupkefu['nowfkid'] = 0; goto Fx6XW; Yggk9: $id = intval($_GPC['id']); goto PkHnT; PGs20: } public function doMobilePcupload() { goto TsUWM; UE8jb: if (file_exists($targetName)) { goto ioeV4; } goto ipqRA; r23Um: if ($isqiniu == 3) { goto fKRay; } goto eiI_z; MANUv: KhD0P: goto MwBWH; CYswr: mXyM2: goto zzllR; bSI9X: $resarr['realimgurl'] = $randimgurl; goto pkOs5; wpgrF: $resarr['imgurl'] = tomedia($randimgurl); goto Sgeb7; G0_9R: MY50O: goto JmM0T; wv02x: o2zcY: goto xDlNv; BcZYk: $resarr['realimgurl'] = $randimgurl; goto FyggK; YMowd: $resarr['realimgurl'] = $randimgurl; goto wpgrF; pVrvo: qutA2: goto JB2on; ipqRA: $resarr['error'] = 1; goto sfbMP; JmM0T: $resarr['error'] = 1; goto ef_Ia; eiI_z: goto MBd4r; goto MANUv; iqo6B: $resarr['message'] = ''; goto RdlS4; nm4se: load()->func('file'); goto s11fL; M0UE3: $resarr['error'] = 0; goto yTjVw; X6zgc: goto mXyM2; goto LpCd2; fNIf2: $resarr['error'] = 1; goto drXCV; Sgeb7: $resarr['message'] = ''; goto PZvlI; LWcf2: $url = $_FILES['jUploaderFile']['tmp_name']; goto FzXhR; drXCV: $resarr['message'] = ''; goto fWcs3; vyWEV: die(json_encode($resarr)); goto X8f34; zzllR: echo json_encode($resarr, true); goto eBt53; gHzxI: fKRay: goto zbM6L; FyggK: $qiniuurl = $this->getmoduleconfig('qiniuurl'); goto csv_0; xDlNv: MBd4r: goto bSI9X; Gmctk: $isqiniu = $this->getmoduleconfig('isqiniu'); goto NbF_O; IqxK1: $targetName = '../attachment/' . $randimgurl; goto yMEvX; QxCMJ: goto lnytp; goto sjVhV; KckrK: if (file_exists($updir)) { goto qutA2; } goto znqJ4; s11fL: $remotestatus = file_remote_upload($randimgurl, true); goto Op29c; KV6jv: $resarr['message'] = ''; goto CYswr; YJOhf: goto fzOkT; goto G0_9R; TsUWM: global $_W, $_FILES, $_GPC; goto LWcf2; MwBWH: $remotestatus = $this->doQiuniu($randimgurl, true); goto VDQYF; ef_Ia: $resarr['message'] = ''; goto vyWEV; znqJ4: mkdir($updir, 0777, true); goto pVrvo; pkOs5: $resarr['imgurl'] = tomedia($randimgurl); goto KV6jv; RdlS4: die(json_encode($resarr)); goto YJOhf; sjVhV: L1cLn: goto fNIf2; Op29c: if (is_error($remotestatus)) { goto L1cLn; } goto YMowd; VieTK: $this->mkThumbnail($targetName, 640, null, $targetName); goto xDG5V; PZvlI: die(json_encode($resarr)); goto QxCMJ; Mb7oJ: goto MBd4r; goto gHzxI; LpCd2: ioeV4: goto M0UE3; fWcs3: die(json_encode($resarr)); goto KMs7F; yMEvX: move_uploaded_file($url, $targetName); goto UE8jb; yTjVw: $img_info = getimagesize($targetName); goto GKwTk; eBt53: exit; goto L2qR_; sfbMP: $resarr['message'] = ''; goto X6zgc; JB2on: $randimgurl = 'images/' . $_W['uniacid'] . '/' . date('Y', time()) . '/' . date('m', time()) . '/' . date('YmdHis') . rand(1000, 9999) . '.jpg'; goto IqxK1; csv_0: $resarr['imgurl'] = $qiniuurl . '/' . $randimgurl; goto iqo6B; xDG5V: u1Ta4: goto Gmctk; GKwTk: if (!($img_info[0] > 640)) { goto u1Ta4; } goto VieTK; X8f34: fzOkT: goto Mb7oJ; zbM6L: if (empty($_W['setting']['remote']['type'])) { goto o2zcY; } goto nm4se; FzXhR: $updir = '../attachment/images/' . $_W['uniacid'] . '/' . date('Y', time()) . '/' . date('m', time()) . '/'; goto KckrK; KMs7F: lnytp: goto wv02x; VDQYF: if (is_error($remotestatus)) { goto MY50O; } goto BcZYk; NbF_O: if ($isqiniu == 1) { goto KhD0P; } goto r23Um; L2qR_: } public function doMobileJietuupload() { goto R5FfB; lbFtq: if ($isqiniu == 3) { goto URD53; } goto UIUnD; n1AEE: Tzaug: goto Ie16P; Ie16P: $resarr['error'] = 1; goto R3NsF; R3NsF: $resarr['message'] = ''; goto gnUK1; UCbQO: $resarr['realimgurl'] = $randimgurl; goto I0voT; aGw7w: $resarr['realimgurl'] = $randimgurl; goto bies8; gnUK1: die(json_encode($resarr)); goto SbRvF; uyM5r: URD53: goto DdLW2; P6cOw: $resarr['realimgurl'] = $randimgurl; goto b7j0N; U1TMt: $base64_body = substr(strstr($base64_url, ','), 1); goto a0rLK; O0_q_: if (is_error($remotestatus)) { goto M4cRq; } goto P6cOw; Q5StC: $resarr['message'] = ''; goto Xpnu1; O34BM: $targetName = '../attachment/' . $randimgurl; goto oRry4; xuoKZ: die(json_encode($resarr)); goto eZjUx; bv2sX: GXVvA: goto xmoSv; iMry7: $base64_url = $_GPC['img']; goto U1TMt; b7j0N: $qiniuurl = $this->getmoduleconfig('qiniuurl'); goto NQBt1; JNx6U: goto VwKNV; goto bOI2e; aq9mu: if (is_error($remotestatus)) { goto Tzaug; } goto UCbQO; C476d: oEv7K: goto FXmgA; UIUnD: goto Bg3UF; goto g4P_2; rtojE: if (file_exists($updir)) { goto GXVvA; } goto z1UWV; mAH1k: goto CsHOc; goto pIfOu; U0LnR: echo json_encode($resarr, true); goto ehovE; SXMTE: $resarr['error'] = 1; goto Q5StC; bOI2e: B0vCv: goto ZvhiH; UijH1: $updir = '../attachment/images/' . $_W['uniacid'] . '/' . date('Y', time()) . '/' . date('m', time()) . '/'; goto rtojE; xP2m5: VwKNV: goto U0LnR; Xpnu1: die(json_encode($resarr)); goto LnKDk; JN2DY: $resarr['error'] = 1; goto kCA7z; SbRvF: VsX7A: goto C476d; Pum_u: die(json_encode($resarr)); goto mAH1k; DdLW2: if (empty($_W['setting']['remote']['type'])) { goto oEv7K; } goto h9CaL; xGQx3: $resarr['message'] = ''; goto xuoKZ; oRry4: file_put_contents($targetName, $base64_data); goto R3KcL; NQBt1: $resarr['imgurl'] = $qiniuurl . '/' . $randimgurl; goto Zs9Kp; h9CaL: load()->func('file'); goto Gbvj0; VFieY: $remotestatus = $this->doQiuniu($randimgurl, true); goto O0_q_; I0voT: $resarr['imgurl'] = tomedia($randimgurl); goto xGQx3; ehovE: exit; goto jGsWi; ZvhiH: $resarr['error'] = 0; goto okucX; xmoSv: $randimgurl = 'images/' . $_W['uniacid'] . '/' . date('Y', time()) . '/' . date('m', time()) . '/' . date('YmdHis') . rand(1000, 9999) . '.jpg'; goto O34BM; CFOKM: goto Bg3UF; goto uyM5r; DM81u: $resarr['message'] = ''; goto xP2m5; eZjUx: goto VsX7A; goto n1AEE; g4P_2: pC20T: goto VFieY; LnKDk: CsHOc: goto CFOKM; Zs9Kp: $resarr['message'] = ''; goto Pum_u; okucX: $img_info = getimagesize($targetName); goto WpQfR; rhAtD: $isqiniu = $this->getmoduleconfig('isqiniu'); goto HK350; Gbvj0: $remotestatus = file_remote_upload($randimgurl, true); goto aq9mu; a0rLK: $base64_data = base64_decode($base64_body); goto UijH1; FXmgA: Bg3UF: goto aGw7w; bies8: $resarr['imgurl'] = tomedia($randimgurl); goto DM81u; R5FfB: global $_W, $_GPC; goto iMry7; R3KcL: if (file_exists($targetName)) { goto B0vCv; } goto JN2DY; pIfOu: M4cRq: goto SXMTE; z1UWV: mkdir($updir, 0777, true); goto bv2sX; kCA7z: $resarr['message'] = ''; goto JNx6U; HK350: if ($isqiniu == 1) { goto pC20T; } goto lbFtq; KrxLi: $this->mkThumbnail($targetName, 640, null, $targetName); goto cNzQo; cNzQo: EpdKn: goto rhAtD; WpQfR: if (!($img_info[0] > 640)) { goto EpdKn; } goto KrxLi; jGsWi: } public function doQiuniu($filename, $auto_delete_local = true) { goto XZBTl; yZYQb: $uploadtoken = $auth->uploadToken($qiniubucket, $filename, 3600, $putpolicy); goto eUNzI; lbTHe: CSWqE: goto xKkeJ; jW_1l: die(json_encode($resarr)); goto lbTHe; UQqFI: $isqiniu = $this->getmoduleconfig('isqiniu'); goto i2YAb; zSvgW: load()->func('file'); goto HmAbW; Zl0bb: $resarr['error'] = 1; goto CCNIT; fjupm: file_delete($filename); goto liD4Y; Ho40V: $qiniusecretkey = $isqiniu == 1 ? $qiniusecretkey : $_W['setting']['remote']['qiniu']['secretkey']; goto pjL9w; CCNIT: $resarr['message'] = ''; goto jW_1l; pjL9w: $qiniubucket = $isqiniu == 1 ? $qiniubucket : $_W['setting']['remote']['qiniu']['bucket']; goto zSvgW; CM6UD: $uploadmgr = new Qiniu\Storage\UploadManager($config); goto jqjcS; i2YAb: $qiniuaccesskey = $this->getmoduleconfig('qiniuaccesskey'); goto EM_Sh; SnUu5: $qiniuaccesskey = $isqiniu == 1 ? $qiniuaccesskey : $_W['setting']['remote']['qiniu']['accesskey']; goto Ho40V; PPVkm: goto CSWqE; goto EhO6l; EhO6l: PzTUi: goto Zl0bb; EM_Sh: $qiniusecretkey = $this->getmoduleconfig('qiniusecretkey'); goto jkNYk; ax8Hd: if (!$auto_delete_local) { goto bunt0; } goto fjupm; sZTig: $auth = new Qiniu\Auth($qiniuaccesskey, $qiniusecretkey); goto EpNZQ; eUNzI: list($ret, $err) = $uploadmgr->putFile($uploadtoken, $filename, ATTACHMENT_ROOT . '/' . $filename); goto ax8Hd; jqjcS: $putpolicy = Qiniu\base64_urlSafeEncode(json_encode(array("scope" => $qiniubucket . ':' . $filename))); goto yZYQb; WbFeL: if ($err !== null) { goto PzTUi; } goto BDt5E; liD4Y: bunt0: goto WbFeL; EpNZQ: $config = new Qiniu\Config(); goto CM6UD; BDt5E: return true; goto PPVkm; jkNYk: $qiniubucket = $this->getmoduleconfig('qiniubucket'); goto SnUu5; HmAbW: require_once IA_ROOT . '/framework/library/qiniu/autoload.php'; goto sZTig; XZBTl: global $_W; goto UQqFI; xKkeJ: } public function mkThumbnail($src, $width = null, $height = null, $filename = null) { goto zwgHU; lTOWq: imagedestroy($src_img); goto i7wwC; AaOgb: return false; goto P2YZI; r8JY3: $height = $src_h * ($width / $src_w); goto mKGDX; M98Hu: xQ6_i: goto cPScg; Rhvs_: $imagefunc($dest_img); goto IevKJ; mKGDX: VzXiu: goto G2QHA; KhE0o: XYohh: goto ahxI0; CTqyh: if (!(isset($width) && $width <= 0)) { goto zNWrT; } goto FxSGm; eZybb: QW4wS: goto puTjY; IevKJ: goto xMBUi; goto eZybb; zt9sF: if (isset($width)) { goto xQ6_i; } goto ugz3n; VIkpL: xMBUi: goto lTOWq; oyxsm: imagecopyresampled($dest_img, $src_img, 0, 0, 0, 0, $width, $height, $src_w, $src_h); goto tdGzI; hlcZ8: if (!(isset($height) && $height <= 0)) { goto NHqX9; } goto AaOgb; tdGzI: $imagefunc = 'image' . $img_type; goto iIygr; ntnH_: zNWrT: goto hlcZ8; ugz3n: $width = $src_w * ($height / $src_h); goto M98Hu; FxSGm: return false; goto ntnH_; zwgHU: if (!(!isset($width) && !isset($height))) { goto v3klQ; } goto xv9xO; i7wwC: imagedestroy($dest_img); goto ZFYx9; vuqZD: $src_mime = $size['mime']; goto AsN9O; P2YZI: NHqX9: goto xJn0l; hbyCO: OVszw: goto GP4D_; puTjY: $imagefunc($dest_img, $filename); goto VIkpL; ZFYx9: return true; goto qrdrP; ahxI0: KJ5ok: goto zt9sF; xJn0l: $size = getimagesize($src); goto UAVco; UAVco: if ($size) { goto OVszw; } goto hxpfc; GP4D_: list($src_w, $src_h, $src_type) = $size; goto vuqZD; LhaIj: header('Content-Type: ' . $src_mime); goto Rhvs_; xv9xO: return false; goto Xb2BV; hxpfc: return false; goto hbyCO; Xb2BV: v3klQ: goto CTqyh; G2QHA: $imagecreatefunc = 'imagecreatefrom' . $img_type; goto XDK2_; AsN9O: switch ($src_type) { case 1: $img_type = 'gif'; goto KJ5ok; case 2: $img_type = 'jpeg'; goto KJ5ok; case 3: $img_type = 'png'; goto KJ5ok; case 15: $img_type = 'wbmp'; goto KJ5ok; default: return false; } goto KhE0o; fEBUi: $dest_img = imagecreatetruecolor($width, $height); goto oyxsm; iIygr: if ($filename) { goto QW4wS; } goto LhaIj; cPScg: if (isset($height)) { goto VzXiu; } goto r8JY3; XDK2_: $src_img = $imagecreatefunc($src); goto fEBUi; qrdrP: } public function getmoduleconfig($key) { goto qUAy8; qUAy8: global $_W, $_GPC; goto hKyyd; hKyyd: $setting = pdo_fetch('SELECT settings FROM ' . tablename('uni_account_modules') . " WHERE uniacid = {$_W['uniacid']} AND module = 'cy163_customerservice'"); goto PyFB_; yTVhT: return $settings[$key]; goto S1qIi; PyFB_: $settings = unserialize($setting['settings']); goto yTVhT; S1qIi: } public function doMobileDuvoice() { goto KxB74; rv3T9: $fkid = intval($_GPC['fkid']); goto VzIbl; Wr49O: $resarr['error'] = 0; goto l_Aul; Rmfx6: $openid = $_SESSION['openid']; goto bXmZi; bXmZi: $media_id = $_GPC['media_id']; goto rv3T9; cwEDX: pdo_update(BEST_CHAT, $dataup, array("id" => $chatres['id'])); goto dyOVS; z5ayY: if (!($chatres['openid'] != $openid)) { goto RJCiQ; } goto CndIc; CndIc: $dataup['hasyuyindu'] = 1; goto cwEDX; KxB74: global $_W, $_GPC; goto Rmfx6; dyOVS: RJCiQ: goto Wr49O; VzIbl: $chatres = pdo_fetch('SELECT * FROM ' . tablename(BEST_CHAT) . " WHERE weid = {$_W['uniacid']} AND content = '{$media_id}' AND fkid = {$fkid}"); goto z5ayY; l_Aul: die(json_encode($resarr)); goto lQcK8; lQcK8: } public function doMobileGetvoice() { goto V3lAb; VIPg_: pdo_update(BEST_CHAT, $dataup, array("id" => $chatres['id'])); goto Klhdo; mFZcd: $resarr['error'] = 1; goto mmbjA; JMkbF: $chatres = pdo_fetch('SELECT * FROM ' . tablename(BEST_CHAT) . " WHERE weid = {$_W['uniacid']} AND content = '{$media_id}' AND fkid = {$fkid}"); goto tfhb2; jEwwV: f72pl: goto qqs05; Mydzf: $resarr['msg'] = ''; goto SwFMK; GIFrS: $chatres = $chatres2; goto rO9Po; if8Zf: $url = 'http://file.api.weixin.qq.com/cgi-bin/media/get?access_token=' . $access_token . '&media_id=' . $media_id; goto BI_7G; f9Uow: $savemp3 = 'audios/' . $_W['uniacid'] . '/' . date('Y', time()) . '/' . date('m', time()) . '/' . date('YmdHis') . rand(1000, 9999) . '.mp3'; goto A9MBE; AGo3R: $qiniusecretkey = $this->getmoduleconfig('qiniusecretkey'); goto dPgbV; SLH1b: $fops = $fops . '|saveas/' . $putpolicy; goto f2m_w; k5bq5: die(json_encode($resarr)); goto D_Nxr; aW21x: $openid = $_SESSION['openid']; goto Iy4Ct; qlGjJ: LiBBe: goto bMfFi; jv1j9: $resarr['error'] = 1; goto bxoal; qqs05: $uploadtoken = $auth->uploadToken($qiniubucket, null, 3600, $policy); goto zn73V; WQjKK: $qiniuurl = $isqiniu == 1 ? $qiniuurl : $_W['setting']['remote']['qiniu']['url']; goto mEI46; hs9um: $resarr['msg'] = ''; goto oa_RL; eqh03: $media_id = $_GPC['media_id']; goto G7E00; V3lAb: global $_W, $_GPC; goto aW21x; RzMhX: $resarr['weidu'] = 1; goto nbdL8; dPgbV: $qiniubucket = $this->getmoduleconfig('qiniubucket'); goto yxBTI; C68kn: AT1cT: goto g3Soy; A8trk: qE2qx: goto Uo8sB; zn73V: list($ret, $err) = $uploadmgr->putFile($uploadtoken, $savemp3, $targetName); goto DP4T3; TMcLY: $dataup['hasyuyindu'] = 1; goto RzMhX; oa_RL: die(json_encode($resarr)); goto QRt2M; A9MBE: load()->func('file'); goto HzTAn; jQJtV: $qiniusecretkey = $isqiniu == 1 ? $qiniusecretkey : $_W['setting']['remote']['qiniu']['secretkey']; goto AAKnR; YpPVI: $dataup['content'] = $qiniuurl . '/' . $ret['key']; goto hFUNf; JaJuD: $resarr['error'] = 1; goto hs9um; ZPlAE: $chatid = intval($_GPC['chatid']); goto JMkbF; bMfFi: $policy = array("persistentOps" => $fops, "persistentPipeline" => $liedui); goto jEwwV; FXNWX: $resarr['error'] = 1; goto Mydzf; kjMaS: die(json_encode($resarr)); goto kFKgC; C_qnv: $resarr['msg'] = ''; goto qmgNj; c4hTY: sleep(5); goto P0ZZ1; AAKnR: $qiniubucket = $isqiniu == 1 ? $qiniubucket : $_W['setting']['remote']['qiniu']['bucket']; goto WQjKK; Mg2Dw: $access_token = $account_api->getAccessToken(); goto if8Zf; KrD1d: $randvoiceurl = 'audios/' . $_W['uniacid'] . '/' . date('Y', time()) . '/' . date('m', time()) . '/' . date('YmdHis') . rand(1000, 9999) . '.amr'; goto QzDu7; iyqVW: HhKXB: goto eqh03; HHfST: JmQwM: goto JaJuD; lfpJL: $resarr['error'] = 1; goto yLRvz; Klhdo: $resarr['error'] = 0; goto SLt0M; ctnIN: bikrR: goto klxJ_; Uo8sB: $account_api = WeAccount::create(); goto Mg2Dw; iIo_t: goto TWh7p; goto HHfST; f2m_w: $liedui = $this->getmoduleconfig('liedui'); goto OOcvO; bxoal: $resarr['msg'] = ''; goto k5bq5; BUi0u: if (file_exists($updir)) { goto hHkfI; } goto UrTjU; uGbCI: $qiniuaccesskey = $isqiniu == 1 ? $qiniuaccesskey : $_W['setting']['remote']['qiniu']['accesskey']; goto jQJtV; P1Si4: $fp = @fopen($targetName, 'wb'); goto mHyjk; wpRrj: hHkfI: goto KrD1d; jhBrl: $policy = array("persistentOps" => $fops); goto OfySr; mHyjk: @fwrite($fp, $response['content']); goto gv0cU; hP4xC: if (!($chatres['mp3du'] == 1)) { goto bikrR; } goto FXNWX; mEI46: if (!($isqiniu == 0 || $qiniuaccesskey == '' || $qiniusecretkey == '' || $qiniubucket == '')) { goto HhKXB; } goto an4qk; tfhb2: if (!empty($chatres)) { goto Cu1G5; } goto gKjRD; qmgNj: die(json_encode($resarr)); goto iyqVW; QzDu7: $targetName = '../attachment/' . $randvoiceurl; goto P1Si4; D_Nxr: YPfYX: goto GIFrS; mmbjA: $resarr['msg'] = ", : {$result['errcode']}, : {$result['errmsg']}"; goto hAWfJ; gKjRD: $chatres2 = pdo_fetch('SELECT * FROM ' . tablename(BEST_CHAT) . " WHERE weid = {$_W['uniacid']} AND id = {$chatid}"); goto apHJT; nbdL8: yAznq: goto nz5H7; qsbs9: $putpolicy = Qiniu\base64_urlSafeEncode($qiniubucket . ':' . $savemp3); goto yJDZY; QDdoV: pdo_update(BEST_CHAT, array("mp3du" => 1), array("id" => $chatres['id'])); goto c4hTY; GyZV8: if (!is_error($response)) { goto y9VTD; } goto lfpJL; rO9Po: Cu1G5: goto hP4xC; UrTjU: mkdir($updir, 0777, true); goto wpRrj; BI_7G: $response = ihttp_get($url); goto GyZV8; SQMDP: $uploadmgr = new Qiniu\Storage\UploadManager($config); goto qsbs9; yF4PK: $resarr['msg'] = ''; goto u_Y0t; kFKgC: y9VTD: goto fjMfY; yxBTI: $qiniuurl = $this->getmoduleconfig('qiniuurl'); goto uGbCI; SwFMK: die(json_encode($resarr)); goto ctnIN; HzTAn: require_once IA_ROOT . '/framework/library/qiniu/autoload.php'; goto m1Rl5; u_Y0t: die(json_encode($resarr)); goto iIo_t; L9qLj: $resarr['voicefile'] = $chatres['content']; goto l4nqc; jvUvz: if (!empty($liedui)) { goto LiBBe; } goto jhBrl; P0ZZ1: file_delete($randvoiceurl); goto YpPVI; o3sR_: if (empty($result['errcode'])) { goto AT1cT; } goto mFZcd; Qx34h: $config = new Qiniu\Config(); goto SQMDP; klxJ_: if (!(strpos($chatres['content'], '.mp3') !== false)) { goto qE2qx; } goto xTVBQ; nz5H7: $dataup['mp3du'] = 0; goto VIPg_; gv0cU: @fclose($fp); goto f9Uow; OOcvO: $liedui = empty($liedui) ? '' : $liedui; goto jvUvz; l4nqc: die(json_encode($resarr)); goto A8trk; SLt0M: $resarr['voicefile'] = $qiniuurl . '/' . $ret['key']; goto yF4PK; xTVBQ: $resarr['error'] = 0; goto L9qLj; yJDZY: $fops = 'avthumb/mp3/ab/320k/ar/44100/acodec/libmp3lame'; goto SLH1b; QRt2M: TWh7p: goto Fq_HP; Iy4Ct: load()->func('communication'); goto Lqbee; hAWfJ: die(json_encode($resarr)); goto C68kn; yLRvz: $resarr['msg'] = ", : {$response['message']}"; goto kjMaS; an4qk: $resarr['error'] = 1; goto C_qnv; DP4T3: if ($err !== null) { goto JmQwM; } goto QDdoV; m1Rl5: $auth = new Qiniu\Auth($qiniuaccesskey, $qiniusecretkey); goto Qx34h; OfySr: goto f72pl; goto qlGjJ; fjMfY: $result = @json_decode($response['content'], true); goto o3sR_; Lqbee: $isqiniu = $this->getmoduleconfig('isqiniu'); goto Tpdzh; hFUNf: if (!($chatres['openid'] != $openid)) { goto yAznq; } goto TMcLY; g3Soy: $updir = '../attachment/audios/' . $_W['uniacid'] . '/' . date('Y', time()) . '/' . date('m', time()) . '/'; goto BUi0u; Tpdzh: $qiniuaccesskey = $this->getmoduleconfig('qiniuaccesskey'); goto AGo3R; G7E00: $fkid = intval($_GPC['fkid']); goto ZPlAE; apHJT: if (!empty($chatres2)) { goto YPfYX; } goto jv1j9; Fq_HP: } public function doWebQianru() { goto pc2ux; CYUCA: g8I7S: goto Afa4b; i3L5C: message('', referer(), 'success'); goto U7b0h; BvXdO: $operation = !empty($_GPC['op']) ? $_GPC['op'] : 'display'; goto uMAHl; Afa4b: $id = intval($_GPC['id']); goto erYfl; mFiAy: foreach ($cservicelist as $k => $v) { goto t6YIU; TqhZ1: $cservicelist[$k]['scripthtml2'] = htmlentities('<a href="' . $scripturl2 . '" style="z-index:10001;position:absolute;right:' . $qrset['qrright2'] . 'px;bottom:' . $qrset['qrbottom2'] . 'px;"><img style="height:auto;width:' . $qrset['qrwidth2'] . 'px;" src="' . tomedia($qrset['qrphonetu']) . '" /></a>'); goto sWXjM; uomXi: $cservicelist[$k]['scripthtml'] = htmlspecialchars($scripthtml); goto KxvP3; lJ43B: lF9OE: goto jQN_3; sWXjM: o2SvA: goto lJ43B; LQqD3: if (!empty($qrset)) { goto lu3C_; } goto CzvWy; gu6b6: goto o2SvA; goto bunRE; bunRE: lu3C_: goto gK01H; Z9dZh: $cservicelist[$k]['scripthtml2'] = ''; goto gu6b6; P743b: $cservicelist[$k]['qrset'] = $qrset; goto nvmTi; CzvWy: $cservicelist[$k]['scripthtml'] = ''; goto Z9dZh; t6YIU: $qrset = unserialize($v['qrmsg']); goto P743b; gK01H: $scripthtml = '<script type="text/javascript" src="' . $_W['siteroot'] . 'addons/cy163_customerservice_plugin_p/static/qianru.js"></script> 
									<script type="text/javascript"> 
										document.getElementById("kfiframe").src="' . $scripturl . '"; 
										var xfkefu = document.getElementById("xfkefu"); 
										xfkefu.style.background = "' . $qrset['qrsetbgcolor'] . '"; 
										xfkefu.style.color = "' . $qrset['qrsettextcolor'] . '"; 
										xfkefu.innerText = "' . $qrset['qrsettext'] . '"; 
										xfkefu.style.fontSize = "' . $qrset['qrsettextsize'] . 'px"; 
										xfkefu.style.lineHeight = xfkefu.style.paddingTop = xfkefu.style.paddingBottom = "' . $qrset['qrsetlineheight'] . 'px"; 
										xfkefu.style.width = "' . $qrset['qrwidth'] . 'px"; 
										xfkefu.style.bottom = "' . $qrset['qrbottom'] . 'px"; 
										xfkefu.style.right = "' . $qrset['qrright'] . 'px"; 
									</script> 
									'; goto uomXi; KxvP3: $scripturl2 = $_W['siteroot'] . 'app/index.php?i=' . $_W['uniacid'] . '&c=entry&do=chat&m=cy163_customerservice&toopenid=' . $v['content']; goto TqhZ1; nvmTi: $scripturl = $_W['siteroot'] . 'app/index.php?i=' . $_W['uniacid'] . '&c=entry&do=index&m=cy163_customerservice_plugin_p&toopenid=' . $v['content']; goto LQqD3; jQN_3: } goto oS6sB; ZyVaB: if ($operation == 'qrset') { goto g8I7S; } goto oa9xg; N9PBO: $cservicelist = pdo_fetchall('SELECT * FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = '{$_W['uniacid']}' AND ctype = 1 ORDER BY displayorder ASC"); goto mFiAy; oS6sB: sxv3F: goto rF4gY; BoMQA: pdo_update(BEST_CSERVICE, $data, array("id" => $id)); goto i3L5C; TDEjg: w54rl: goto N9PBO; pc2ux: global $_GPC, $_W; goto BvXdO; fuXEg: include $this->template('web/qianru'); goto AiCQm; uMAHl: if ($operation == 'display') { goto w54rl; } goto ZyVaB; rF4gY: goto bdt4Y; goto CYUCA; erYfl: $qrset = array("qrsetbgcolor" => trim($_GPC['qrsetbgcolor']), "qrsettextcolor" => trim($_GPC['qrsettextcolor']), "qrsettext" => trim($_GPC['qrsettext']), "qrsettextsize" => intval($_GPC['qrsettextsize']), "qrwidth" => intval($_GPC['qrwidth']), "qrbottom" => intval($_GPC['qrbottom']), "qrright" => intval($_GPC['qrright']), "qrsetlineheight" => intval($_GPC['qrsetlineheight']), "qrphonetu" => trim($_GPC['qrphonetu']), "qrbottom2" => intval($_GPC['qrbottom2']), "qrright2" => intval($_GPC['qrright2']), "qrwidth2" => intval($_GPC['qrwidth2'])); goto ImSig; oa9xg: goto bdt4Y; goto TDEjg; ImSig: $data['qrmsg'] = serialize($qrset); goto BoMQA; U7b0h: bdt4Y: goto fuXEg; AiCQm: } public function doWebCservice() { goto Y2HyS; OVoYc: if ($operation == 'display') { goto BJ3aK; } goto p10uS; HxZFv: tfS5Y: goto PelGc; gjGBm: $data['pwd'] = sha1($pwd); goto gv2lh; vkQG6: $user = trim($_GPC['user']); goto F4Urg; kuGe1: goto rAGm9; goto HxZFv; ux0S4: $cservicelist = pdo_fetchall('SELECT * FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = '{$_W['uniacid']}' AND ctype = 1 ORDER BY displayorder ASC"); goto fWIuB; nxIlM: echo json_encode($resArr); goto lQ6To; x9z3n: $resArr['error'] = 0; goto muZRv; vJrSX: if ($operation == 'changepwd') { goto vtIIg; } goto DZrWL; X0TAV: echo json_encode($resArr); goto ftuh0; iQNdj: $resArr['error'] = 1; goto gzN4P; dpxGh: echo json_encode($resArr); goto lse9n; lse9n: exit; goto Eg1Nd; fsv6m: $id = intval($_GPC['id']); goto GNE8C; GCZ3W: JTjrR: goto VeBLQ; gzN4P: $resArr['msg'] = ''; goto i6xW6; fWIuB: include $this->template('web/cservice'); goto kuGe1; m9Ubv: $resArr['msg'] = ''; goto LWc4f; y3_XX: yuLWa: goto U0CQa; MlfYh: $resArr['error'] = 1; goto sl3jJ; DZrWL: goto rAGm9; goto AHW4e; Wmi7G: if (!empty($pwd)) { goto vudYj; } goto F197c; jH8VT: $resArr['error'] = 0; goto AsVa6; oR82H: echo json_encode($resArr); goto UnW89; AHW4e: BJ3aK: goto ux0S4; AnDJO: $resArr['error'] = 1; goto m9Ubv; Eg1Nd: vudYj: goto cgAfQ; AsVa6: $resArr['msg'] = '' . $cservice['name'] . ''; goto X0TAV; DpDIN: $operation = !empty($_GPC['op']) ? $_GPC['op'] : 'display'; goto OVoYc; eiYpl: exit; goto y3_XX; nMvkL: goto rAGm9; goto gH1ku; gH1ku: vtIIg: goto fsv6m; zPphY: echo json_encode($resArr); goto Y4oEe; muZRv: $resArr['msg'] = '' . $cservice['name'] . ''; goto zPphY; PelGc: $id = intval($_GPC['id']); goto vkQG6; Y4oEe: exit; goto nMvkL; Vnfkn: $resArr['error'] = 1; goto il_w2; nrG65: Zlg0o: goto gjGBm; Y2HyS: global $_GPC, $_W; goto DpDIN; GNE8C: $pwd = trim($_GPC['pwd']); goto Wmi7G; sl3jJ: $resArr['msg'] = ''; goto nxIlM; VeBLQ: $data['username'] = $user; goto yiy_K; WEXTq: if (!empty($cservice)) { goto JTjrR; } goto AnDJO; F197c: $resArr['error'] = 1; goto NPK_R; ftuh0: exit; goto LuJ8M; aTF6q: if (!empty($cservice)) { goto Zlg0o; } goto MlfYh; zBun2: exit; goto GCZ3W; p10uS: if ($operation == 'changeuser') { goto tfS5Y; } goto vJrSX; gv2lh: pdo_update(BEST_CSERVICE, $data, array("id" => $id)); goto jH8VT; O5vpL: Kqwg0: goto ziy65; LWc4f: echo json_encode($resArr); goto zBun2; LuJ8M: rAGm9: goto WhRX7; yiy_K: pdo_update(BEST_CSERVICE, $data, array("id" => $id)); goto x9z3n; lQ6To: exit; goto nrG65; sZAW4: if (empty($hasuser)) { goto yuLWa; } goto iQNdj; U0CQa: $cservice = pdo_fetch('SELECT * FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = '{$_W['uniacid']}' AND id= {$id} AND ctype = 1"); goto WEXTq; cgAfQ: $cservice = pdo_fetch('SELECT * FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = '{$_W['uniacid']}' AND id= {$id} AND ctype = 1"); goto aTF6q; NPK_R: $resArr['msg'] = ''; goto dpxGh; F4Urg: if (!empty($user)) { goto Kqwg0; } goto Vnfkn; i6xW6: echo json_encode($resArr); goto eiYpl; UnW89: exit; goto O5vpL; il_w2: $resArr['msg'] = ''; goto oR82H; ziy65: $hasuser = pdo_fetch('SELECT id FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = '{$_W['uniacid']}' AND username = '{$user}' AND ctype = 1"); goto sZAW4; WhRX7: } public function doWebCgroup() { goto SEdt0; TTbgI: $cservicegrouplist = pdo_fetchall('SELECT * FROM ' . tablename(BEST_CSERVICEGROUP) . " WHERE weid = {$_W['uniacid']} ORDER BY displayorder ASC"); goto ZHsTI; ZHsTI: foreach ($cservicegrouplist as $k => $v) { $cservicegrouplist[$k]['servicegroupurl'] = $_W['siteroot'] . 'app/' . str_replace('./', '', $this->createMobileUrl('index', array("groupid" => $v['id']))); FeVrH: } goto qp7Hc; PRlye: include $this->template('web/cgroup'); goto IXCD2; qp7Hc: uwEN1: goto PRlye; SEdt0: global $_W, $_GPC; goto TTbgI; IXCD2: } public function doMobileIndex() { goto K1ylF; UikHS: Kow9k: goto vO3fV; bfzZj: $fangkearr = array("lang" => $this->get_lang(), "browse" => $this->browse_info(), "os" => $this->get_os(), "ip" => $_W['clientip'], "laiyuan" => $_SERVER['HTTP_REFERER'], "latitude" => $ipres['result']['location']['lat'], "longitude" => $ipres['result']['location']['lng'], "nation" => $ipres['result']['ad_info']['nation'], "province" => $ipres['result']['ad_info']['province'], "city" => $ipres['result']['ad_info']['city'], "district" => $ipres['result']['ad_info']['district'], "gzhname" => $_W['account']['name']); goto A6DBr; k4vT8: ouzN3: goto d2CnO; vRDFN: pzeYX: goto PSNuA; u0lEG: M8bjX: goto w0H0f; l73vh: foreach ($chatcon as $k => $v) { goto YSel7; VDT1Y: $chatcon[$k]['time'] = $v['time']; goto pAmUc; pAmUc: Wu4J1: goto lC224; bTm3f: Y3Gca: goto IJzfk; VuiQM: $regex = '@(?i)\\b((?:[a-z][\\w-]+:(?:/{1,3}|[a-z0-9%])|www\\d{0,3}[.]|[a-z0-9.\\-]+[.][a-z]{2,4}/)(?:[^\\s()<>]+|\\(([^\\s()<>]+|(\\([^\\s()<>]+\\)))*\\))+(?:\\(([^\\s()<>]+|(\\([^\\s()<>]+\\)))*\\)|[^\\s`!()\\[\\]{};:\'".,<>?]))@'; goto v2AJ6; ENaLd: mu63d: goto bTm3f; LY1T8: foreach ($array2[0] as $kk => $vv) { goto e1wsr; R1tbu: $chatcon[$k]['content'] = str_replace($vv, '<a href=\'' . $vv . '\'>' . $vv . '</a>', $chatcon[$k]['content']); goto SFqCY; SFqCY: uT62j: goto fMzBz; fMzBz: VB97u: goto Krnin; e1wsr: if (empty($vv)) { goto uT62j; } goto R1tbu; Krnin: } goto Sh3Lz; Sh3Lz: yAejO: goto ENaLd; lC224: $chatcontime = $v['time']; goto ORjYb; YSel7: if ($v['time'] - $chatcontime > 7200) { goto a3rkL; } goto jW4AI; ORjYb: $chatcon[$k]['content'] = preg_replace('/\\xEE[\\x80-\\xBF][\\x80-\\xBF]|\\xEF[\\x81-\\x83][\\x80-\\xBF]/', '[]', $v['content']); goto dtFC0; D5t4q: if (!(!empty($array2[0]) && ($v['type'] == 1 || $v['type'] == 2))) { goto mu63d; } goto LY1T8; jW4AI: $chatcon[$k]['time'] = ''; goto VE_2r; v2AJ6: preg_match_all($regex, $chatcon[$k]['content'], $array2); goto D5t4q; qs_p8: a3rkL: goto VDT1Y; VE_2r: goto Wu4J1; goto qs_p8; dtFC0: $chatcon[$k]['content'] = $this->guolv($chatcon[$k]['content']); goto VuiQM; IJzfk: } goto JFm28; d2CnO: $fkid = $hasfanskefu['id']; goto IsTBB; JFm28: wGfgn: goto pmfbM; ep2iE: $datafanskefu['fansopenid'] = $openid; goto F1cQQ; vO3fV: $chatcon = pdo_fetchall('SELECT * FROM ' . tablename(BEST_CHAT) . " WHERE fkid = {$hasfanskefu['id']} AND weid = {$_W['uniacid']} AND type != 5 AND type != 6 ORDER BY time ASC"); goto pGRS7; bQsgE: $ipurl = 'https://apis.map.qq.com/ws/location/v1/ip?ip=' . $_W['clientip'] . '&key=' . $mapkey; goto r8Hnj; aB8HA: $condition .= ' AND ((day6 = 1 AND isxingqi = 1) OR isxingqi = 0))'; goto UWohe; pGRS7: $chatcontime = 0; goto l73vh; y9a6R: $kefuids = array(0); goto qT_xG; fPXkQ: $ipres = json_decode($ipres, true); goto A2gj9; kdZ_a: $datafanskefu['fansnickname'] = ''; goto dnMUc; Ocp_N: $ipres = file_get_contents($ipurl); goto Jxo8r; Gp4IH: goto kyoKS; goto Ia6T5; dFKUq: goto qaUOV; goto CTSDw; shG19: pdo_update(BEST_FANSKEFU, $datafanskefuup, array("id" => $fkid)); goto GI5RH; CTSDw: IfMbv: goto HraMZ; Sbh3Y: $ipurl = 'https://apis.map.qq.com/ws/location/v1/ip?ip=' . $_W['clientip'] . '&key=' . $mapkey; goto vAH7x; AoBXV: $nowhour = intval(date('H', TIMESTAMP)); goto mcwsp; IjweE: $longitude = $ipres['result']['location']['lng'] . random(4, 1); goto rchsg; GNzN4: if (!($zhouji == '1')) { goto FihFC; } goto OfskB; mesm9: if ($suiji == 1) { goto jsoyT; } goto ibCWZ; oF1Kc: $openid = md5($jiamistr); goto Ys6Vw; TAU8p: $orderby = ' ORDER BY rand()'; goto B3l1x; II3Mz: foreach ($array2[0] as $kk => $vv) { goto QtyVG; T0UA0: $cservice['autoreply'] = str_replace($vv, '<a href=\'' . $vv . '\'>' . $vv . '</a>', $cservice['autoreply']); goto TRy_y; TRy_y: tf7sz: goto mtwaJ; mtwaJ: yp_j1: goto UQ0Xl; QtyVG: if (empty($vv)) { goto tf7sz; } goto T0UA0; UQ0Xl: } goto Y2NyU; iYdC7: nA3lK: goto bIC0z; uhURu: $nowhour = intval(date('H', TIMESTAMP)); goto gbt16; RcjRP: $cservice = pdo_fetch('SELECT * FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = {$_W['uniacid']} AND ctype = 1 AND content = '{$toopenid}'"); goto Nu2J4; ckOP6: $condition .= ' AND ((day3 = 1 AND isxingqi = 1) OR isxingqi = 0))'; goto KrVZj; azQoA: UqazJ: goto UikHS; vAH7x: $ipres = file_get_contents($ipurl); goto fPXkQ; r0_vZ: $jiamistr = $this->get_lang() . $this->browse_info() . $this->get_os() . $latitude . $longitude; goto oF1Kc; So2Ao: if (empty($array2[0])) { goto UqazJ; } goto II3Mz; Rj_dI: if (!empty($cservicegroup)) { goto iHlmL; } goto u4QQU; ibyJp: $datafanskefuup['fangke'] = serialize($fangkearr); goto hW4Zk; Fo4eC: $datafanskefu['fansavatar'] = tomedia($defaultavatar); goto kdZ_a; Ia6T5: brtzz: goto zA3Kk; ZMUDJ: $fangkearr = unserialize($hasfanskefu['fangke']); goto QtWdq; SLECI: $condition .= ' AND ((day2 = 1 AND isxingqi = 1) OR isxingqi = 0))'; goto AHSWp; lXarb: goto zuMSi; goto DuR8R; pSWC8: if (!empty($cservicegroup)) { goto brtzz; } goto AoBXV; fbXoZ: $cservicelist = pdo_fetchall('SELECT * FROM ' . tablename(BEST_CSERVICE) . ' WHERE ' . $condition . $orderby); goto Rj_dI; DuR8R: jsoyT: goto TAU8p; dnMUc: $datafanskefu['kefuavatar'] = tomedia($cservice['thumb']); goto s1YN0; Ys6Vw: $toopenid = trim($_GPC['toopenid']); goto lwYtA; gzzMu: $condition .= ' AND ((day4 = 1 AND isxingqi = 1) OR isxingqi = 0))'; goto iMVgQ; C0Z8i: include $this->template('pcchat'); goto HL0TJ; Y2NyU: bMG2h: goto azQoA; uol_S: $condition = "weid = {$_W['uniacid']} AND ctype = 1 AND ((iszx = 0 AND ( 
					(lingjie = 0 AND endhour >= {$nowhouradd} AND starthour <= {$nowhour}) OR  
					(lingjie = 1 AND (starthour < {$nowhouradd} OR endhour > {$nowhour})) 
				)"; goto Gp4IH; FubO6: $latitude = $_COOKIE['kflatitude']; goto frfxY; s1YN0: $datafanskefu['kefunickname'] = $cservice['name']; goto Zrev8; iMVgQ: NhtKX: goto q8hTJ; IsTBB: if (!$cservice['autoreply']) { goto Kow9k; } goto cvDUT; B3l1x: zuMSi: goto fbXoZ; UWohe: gsFcH: goto B60qy; F1cQQ: $datafanskefu['kefuopenid'] = $cservice['content']; goto Fo4eC; tp0V5: $fangkearr['laiyuan'] = $_SERVER['HTTP_REFERER']; goto PV4KZ; TIXrP: CIaNL: goto uhURu; PSNuA: if (!($zhouji == '6')) { goto gsFcH; } goto aB8HA; MmdIJ: $zhouji = date('w'); goto GNzN4; FAaH0: FihFC: goto BIAyE; mYwkz: setcookie('kflongitude', $longitude, time() + 3600 * 24 * 7); goto ZdvlN; bIC0z: $condition .= ' OR (iszx = 1 AND isrealzx = 1))'; goto hNBDM; pmfbM: $datafanskefuup['kefunotread'] = 0; goto shG19; J8amD: $condition .= ' AND ((day7 = 1 AND isxingqi = 1) OR isxingqi = 0))'; goto iYdC7; OfskB: $condition .= ' AND ((day1 = 1 AND isxingqi = 1) OR isxingqi = 0))'; goto FAaH0; M44Xl: JtH7f: goto a9n2Q; B60qy: if (!($zhouji == '0')) { goto nA3lK; } goto J8amD; mcwsp: $nowhouradd = $nowhour + 1; goto uol_S; a9n2Q: if (empty($toopenid)) { goto E4GE3; } goto RcjRP; AHSWp: LuD1Z: goto F3qYx; Nu2J4: $auto = explode('|', $cservice['fansauto']); goto a6kfH; gDpPD: if (empty($hasfanskefu)) { goto cUDCk; } goto ZMUDJ; a6kfH: $hasfanskefu = pdo_fetch('SELECT * FROM ' . tablename(BEST_FANSKEFU) . " WHERE weid = {$_W['uniacid']} AND fansopenid = '{$openid}' AND kefuopenid = '{$toopenid}'"); goto gDpPD; yyUdT: E4GE3: goto C0Z8i; hWSKn: $title = ''; goto M44Xl; lwYtA: if (!empty($toopenid)) { goto JtH7f; } goto p7Y3I; BIAyE: if (!($zhouji == '2')) { goto LuD1Z; } goto SLECI; ibCWZ: $orderby = ' ORDER BY displayorder ASC'; goto lXarb; UEag9: preg_match_all($regex, $cservice['autoreply'], $array2); goto So2Ao; Mex1E: $mapkey = $this->getmoduleconfig('mapkey'); goto hraz2; PV4KZ: $fangkearr['gzhname'] = $_W['account']['name']; goto dFKUq; r8Hnj: $ipres = file_get_contents($ipurl); goto Ee3Zv; hL0Cj: $condition .= ' AND ((day5 = 1 AND isxingqi = 1) OR isxingqi = 0))'; goto vRDFN; q4yGx: pdo_insert(BEST_FANSKEFU, $datafanskefu); goto SsVsr; UdUSY: qaUOV: goto ibyJp; mcB3C: cUDCk: goto bQsgE; yNAEM: kyoKS: goto MmdIJ; gbt16: $nowhouradd = $nowhour + 1; goto NPZ0I; w0H0f: iHlmL: goto hWSKn; bqXTd: $cservicegroup = pdo_fetch('SELECT * FROM ' . tablename(BEST_CSERVICEGROUP) . " WHERE weid = {$_W['uniacid']} AND id = {$groupid}"); goto pSWC8; AAuxl: UbIek: goto Sbh3Y; HraMZ: $ipurl = 'https://apis.map.qq.com/ws/location/v1/ip?ip=' . $_W['clientip'] . '&key=' . $mapkey; goto Ocp_N; rchsg: setcookie('kflatitude', $latitude, time() + 3600 * 24 * 7); goto mYwkz; GI5RH: $title = '' . $cservice['name'] . ''; goto yyUdT; QX2aC: $fangkearr = array("lang" => $this->get_lang(), "browse" => $this->browse_info(), "os" => $this->get_os(), "ip" => $_W['clientip'], "laiyuan" => $_SERVER['HTTP_REFERER'], "latitude" => $ipres['result']['location']['lat'], "longitude" => $ipres['result']['location']['lng'], "nation" => $ipres['result']['ad_info']['nation'], "province" => $ipres['result']['ad_info']['province'], "city" => $ipres['result']['ad_info']['city'], "district" => $ipres['result']['ad_info']['district'], "gzhname" => $_W['account']['name']); goto UdUSY; A2gj9: $latitude = $ipres['result']['location']['lat'] . random(4, 1); goto IjweE; q8hTJ: if (!($zhouji == '5')) { goto pzeYX; } goto hL0Cj; gAdQO: if (empty($_COOKIE['kflatitude'])) { goto UbIek; } goto FubO6; u4QQU: foreach ($cservicelist as $k => $v) { goto o13Qe; eoSre: if (empty($kefuandgroup)) { goto JOqUm; } goto jEgxq; jEgxq: unset($cservicelist[$k]); goto DbFz8; PRLmU: KNTJY: goto irfbr; o13Qe: $kefuandgroup = pdo_fetch('SELECT id FROM ' . tablename(BEST_KEFUANDGROUP) . " WHERE kefuid = {$v['id']}"); goto eoSre; DbFz8: JOqUm: goto PRLmU; irfbr: } goto u0lEG; cvDUT: $regex = '@(?i)\\b((?:[a-z][\\w-]+:(?:/{1,3}|[a-z0-9%])|www\\d{0,3}[.]|[a-z0-9.\\-]+[.][a-z]{2,4}/)(?:[^\\s()<>]+|\\(([^\\s()<>]+|(\\([^\\s()<>]+\\)))*\\))+(?:\\(([^\\s()<>]+|(\\([^\\s()<>]+\\)))*\\)|[^\\s`!()\\[\\]{};:\'".,<>?]))@'; goto UEag9; A6DBr: $datafanskefu['weid'] = $_W['uniacid']; goto ep2iE; zA3Kk: $kefuandgroup = pdo_fetchall('SELECT kefuid FROM ' . tablename(BEST_KEFUANDGROUP) . " WHERE weid = {$_W['uniacid']} AND groupid = {$cservicegroup['id']}"); goto y9a6R; K1ylF: global $_W, $_GPC; goto Mex1E; Ee3Zv: $ipres = json_decode($ipres, true); goto bfzZj; Jxo8r: $ipres = json_decode($ipres, true); goto QX2aC; F3qYx: if (!($zhouji == '3')) { goto uqMNR; } goto ckOP6; hNBDM: $suiji = $this->getmoduleconfig('suiji'); goto mesm9; SsVsr: $hasfanskefu = pdo_fetch('SELECT * FROM ' . tablename(BEST_FANSKEFU) . " WHERE weid = {$_W['uniacid']} AND fansopenid = '{$openid}' AND kefuopenid = '{$toopenid}'"); goto k4vT8; hW4Zk: goto ouzN3; goto mcB3C; ZdvlN: wZAgh: goto r0_vZ; PB0YJ: goto wZAgh; goto AAuxl; hraz2: $defaultavatar = $this->getmoduleconfig('defaultavatar'); goto gAdQO; frfxY: $longitude = $_COOKIE['kflongitude']; goto PB0YJ; NPZ0I: $condition = "weid = {$_W['uniacid']} AND id in (" . implode(',', $kefuids) . ") AND ((iszx = 0 AND ( 
					(lingjie = 0 AND endhour >= {$nowhouradd} AND starthour <= {$nowhour}) OR  
					(lingjie = 1 AND (starthour < {$nowhouradd} OR endhour > {$nowhour})) 
				)"; goto yNAEM; qT_xG: foreach ($kefuandgroup as $k => $v) { $kefuids[] = $v['kefuid']; thNW3: } goto TIXrP; Zrev8: $datafanskefu['fangke'] = serialize($fangkearr); goto q4yGx; Lgl56: if (!($zhouji == '4')) { goto NhtKX; } goto gzzMu; KrVZj: uqMNR: goto Lgl56; QtWdq: if ($fangkearr['latitude'] == '' || $fangkearr['ip'] != $_W['clientip']) { goto IfMbv; } goto tp0V5; p7Y3I: $groupid = intval($_GPC['groupid']); goto bqXTd; HL0TJ: } public function updatenowjdnum() { goto Rp0cx; lJ66M: RqDSh: goto JxJrO; Rp0cx: global $_W, $_GPC; goto yHXqF; dxFLF: foreach ($cservicelist as $k => $v) { goto wkmTp; MV28Q: pdo_update(BEST_CSERVICE, $data, array("id" => $v['id'])); goto aKEdP; wkmTp: $nowjdnum = pdo_fetchcolumn('SELECT COUNT(*) FROM ' . tablename(BEST_FANSKEFU) . " WHERE weid = {$_W['uniacid']} AND nowjd > 0 AND kefuopenid = '{$v['content']}'"); goto NcwHc; NcwHc: if (empty($nowjdnum)) { goto W0W8D; } goto ubjeT; ubjeT: $data['nowjdnum'] = $nowjdnum; goto MV28Q; mcuq_: A_dwc: goto tCXnK; aKEdP: W0W8D: goto mcuq_; tCXnK: } goto lJ66M; yHXqF: $cservicelist = pdo_fetchall('SELECT id,content FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = {$_W['uniacid']} AND ctype = 1"); goto dxFLF; JxJrO: } public function doMobileXiaxian() { goto hxly9; YVLyF: $data['kfzx'] = 0; goto uJVzU; eutQk: $data['kefunotread'] = 0; goto EoUMr; uJVzU: $data['notread'] = 0; goto HnD_o; aX0gW: GksC7: goto dUasw; cV30a: $data['fszx'] = 0; goto eutQk; EoUMr: pdo_update(BEST_FANSKEFU, $data, array("id" => $fkid)); goto hA3At; gx4Gb: $fkid = intval($_GPC['fkid']); goto Pvg8M; QSPgq: if (!($type == 'kefu')) { goto GksC7; } goto YVLyF; hxly9: global $_W, $_GPC; goto gx4Gb; Pvg8M: $type = trim($_GPC['type']); goto wtkbA; wtkbA: if (!($type == 'fans')) { goto PVa5Z; } goto cV30a; HnD_o: pdo_update(BEST_FANSKEFU, $data, array("id" => $fkid)); goto aX0gW; hA3At: PVa5Z: goto QSPgq; dUasw: } public function doMobileShangxian() { goto ZY92o; yFXd4: pdo_update(BEST_FANSKEFU, $data, array("id" => $fkid)); goto KPten; Lco0A: if (!($type == 'fans')) { goto kCbGH; } goto BFBck; BFBck: $data['fszx'] = 1; goto yFXd4; eve6F: $fkid = intval($_GPC['fkid']); goto sk0Ka; EQ5hL: if (!($type == 'kefu')) { goto YpqDW; } goto wXTfx; wXTfx: $data['kfzx'] = 1; goto m9bZG; h0Fkc: YpqDW: goto O4Eo8; sk0Ka: $type = trim($_GPC['type']); goto Lco0A; m9bZG: pdo_update(BEST_FANSKEFU, $data, array("id" => $fkid)); goto h0Fkc; ZY92o: global $_W, $_GPC; goto eve6F; KPten: kCbGH: goto EQ5hL; O4Eo8: } public function doMobileGetnew() { goto rlRVS; Dxd8D: $fansopenids = array(); goto G0O3r; XBz79: $newfans = pdo_fetchall('SELECT * FROM ' . tablename(BEST_FANSKEFU) . " WHERE weid = {$_W['uniacid']} AND kefuopenid = '{$openid}' AND notread > 0 ORDER BY lasttime DESC"); goto oW69u; t2NG5: $resArr['fansopenids'] = $fansopenids; goto prjg7; G0O3r: if (empty($newfans)) { goto y3kxj; } goto qmLoo; nqyid: exit; goto GeIzp; dFwVW: y3kxj: goto jgkIz; prjg7: echo json_encode($resArr); goto nqyid; J2acT: JyS0W: goto dFwVW; rlRVS: global $_W, $_GPC; goto Oh61M; qmLoo: foreach ($newfans as $k => $v) { goto HOchU; H2E1x: $notread = ''; goto UUDI7; Mnt2k: czmtX: goto Ke2xu; Ke2xu: $notread = '<span class="notread">' . $v['notread'] . '</span>'; goto wimHe; M5VwF: $fansopenids[$k] = $v['fansopenid']; goto Cs8_a; UUDI7: goto UHhDF; goto Mnt2k; Cs8_a: Loewx: goto QT0px; wimHe: UHhDF: goto WtJ7e; HOchU: if ($v['notread'] > 0) { goto czmtX; } goto H2E1x; WtJ7e: $html .= '<a href="' . $this->createMobileUrl('kefucenter', array("toopenid" => $v['fansopenid'])) . '" style="color:#fff;"> 
						<li data-openid="' . $v['fansopenid'] . '" class="new" style="position:relative;"> 
							<img class="avatar" src="' . $v['fansavatar'] . '" width="30" height="30"> 
							<p class="name">' . $v['fansnickname'] . '</p> 
							' . $notread . ' 
						</li></a>'; goto M5VwF; QT0px: } goto J2acT; Oh61M: $openid = $_SESSION['openid']; goto XBz79; oW69u: $html = ''; goto Dxd8D; jgkIz: $resArr['html'] = $html; goto t2NG5; GeIzp: } public function doMobileDonotread() { goto TvIIf; MUdMd: pdo_update(BEST_FANSKEFU, $data, array("id" => $fkid)); goto tgXvs; fSxbi: pdo_update(BEST_FANSKEFU, $data, array("id" => $fkid)); goto WDUVN; tgXvs: USyAj: goto R7Mwl; Nmv0E: $type = trim($_GPC['type']); goto WAATc; iHwZ2: $data['notread'] = 0; goto fSxbi; TvIIf: global $_W, $_GPC; goto bmcAR; MAJkG: $data['kefunotread'] = 0; goto MUdMd; R7Mwl: if (!($type == 'kefu')) { goto zeHhB; } goto iHwZ2; WDUVN: zeHhB: goto MAq4s; WAATc: if (!($type == 'fans')) { goto USyAj; } goto MAJkG; bmcAR: $fkid = intval($_GPC['fkid']); goto Nmv0E; MAq4s: } public function doMobileDonotread2() { goto sYPTq; sYPTq: global $_W, $_GPC; goto IT50i; tXdlc: pdo_update(BEST_XCXFANSKEFU, $data, array("id" => $fkid)); goto f9zgE; IT50i: $fkid = intval($_GPC['fkid']); goto LOekW; LOekW: $data['notread'] = 0; goto tXdlc; f9zgE: } public function doMobileAddbiaoqian() { goto u7tg8; E5dJL: exit; goto elDrT; v6egk: echo json_encode($resArr); goto NJQX5; J2kqP: $has = pdo_fetch('SELECT * FROM ' . tablename(BEST_BIAOQIAN) . " WHERE kefuopenid = '{$openid}' AND fensiopenid = '{$toopenid}' AND weid = {$_W['uniacid']}"); goto DgHRH; fB0RY: $data['name'] = $name; goto bCrax; w46Z0: VFWvw: goto Qgakk; NJQX5: exit; goto ZD5VG; Cxijo: $resArr['msg'] = ''; goto v6egk; xet3m: $data['weid'] = $_W['uniacid']; goto Ux0jc; apzXq: $toopenid = trim($_GPC['toopenid']); goto J2kqP; DCJFO: echo json_encode($resArr); goto c9l27; Ux0jc: $data['kefuopenid'] = $openid; goto WqAz3; u7tg8: global $_W, $_GPC; goto LIX9d; GhHYB: $resArr['msg'] = ''; goto mrqtv; K83Qq: $resArr['error'] = 1; goto GhHYB; RN6SI: $resArr['error'] = 1; goto CNvE0; LIX9d: $openid = $_SESSION['openid']; goto Dhn7p; Jenmq: dDtft: goto YFK4C; c9l27: exit; goto w46Z0; e8h0n: if (!empty($name)) { goto Ir672; } goto K83Qq; SOZ6O: $data['telphone'] = $telphone; goto j3w25; VnlOD: $telphone = trim($_GPC['telphone']); goto apzXq; Dhn7p: if (!empty($openid)) { goto VFWvw; } goto RN6SI; BFazh: $realname = trim($_GPC['realname']); goto VnlOD; DgHRH: if ($has) { goto cs9Lu; } goto xet3m; WqAz3: $data['fensiopenid'] = $toopenid; goto fB0RY; dlDtt: pdo_update(BEST_BIAOQIAN, array("name" => $name, "realname" => $realname, "telphone" => $telphone), array("kefuopenid" => $openid, "fensiopenid" => $toopenid, "weid" => $_W['uniacid'])); goto Jenmq; YFK4C: $resArr['error'] = 0; goto Cxijo; Qgakk: $name = trim($_GPC['name']); goto e8h0n; mrqtv: echo json_encode($resArr); goto E5dJL; Xi_JK: goto dDtft; goto yG2ZC; j3w25: pdo_insert(BEST_BIAOQIAN, $data); goto Xi_JK; yG2ZC: cs9Lu: goto dlDtt; CNvE0: $resArr['msg'] = ''; goto DCJFO; elDrT: Ir672: goto BFazh; bCrax: $data['realname'] = $realname; goto SOZ6O; ZD5VG: } public function sendtplmsg($senddata) { goto Nmr1W; lH0EZ: if (!($istplon == 1)) { goto VaXXd; } goto M0YXb; f2y2S: $account_api->sendTplNotice($senddata['openid'], $tpl_kefu, $postdata, $senddata['url'], '#980000'); goto M1TEf; Nmr1W: global $_GPC, $_W; goto rq0C6; qcM2E: RURp5: goto hlBSY; yVJA2: $account_api->sendCustomNotice($send); goto FefZ4; H7yGN: $texturl = '<a href=\'' . $senddata['url'] . '\'></a>'; goto eoA3d; Knihv: $account_api = WeAccount::create(); goto yVJA2; rq0C6: $istplon = $this->getmoduleconfig('istplon'); goto Fbb0A; Fbb0A: $tpl_kefu = $this->getmoduleconfig('tpl_kefu'); goto lH0EZ; M0YXb: if ($tpl_kefu != '' && $senddata['wherefrom'] != 1) { goto RURp5; } goto H7yGN; M1TEf: oeA0n: goto ZWbab; hlBSY: $postdata = array("keyword1" => array("value" => $senddata['keyword1'], "color" => "#ff510"), "keyword2" => array("value" => date('Y-m-d H:i:s', TIMESTAMP), "color" => "#ff510"), "remark" => array("value" => $senddata['first'], "color" => "#0000CD")); goto mAto1; mAto1: $account_api = WeAccount::create(); goto f2y2S; SclZX: $send['msgtype'] = 'text'; goto fD6qs; ZWbab: VaXXd: goto ns1t9; fD6qs: $send['text'] = array("content" => urlencode($senddata['first'])); goto Knihv; FefZ4: goto oeA0n; goto qcM2E; eoA3d: $send['touser'] = $senddata['openid']; goto SclZX; ns1t9: } public function doMobileAddchat() { goto Cpq0Z; shoeG: ahzno: goto qQvMc; WjA09: $datajqr['nickname'] = $cservice['name']; goto REEuf; Nz2gh: $dataup_fanskefu['nowjd'] = 1; goto g6KTN; cguNz: sIZP_: goto mdszJ; wt2Lz: echo json_encode($resArr); goto Zw8p1; imCU0: FBSRH: goto ZZJBi; iALbv: $datajqr['content'] = $zdhf['allcon']; goto Z8GxE; M3CIq: $tplurl = str_replace('cy163_customerservice_plugin_p', 'cy163_customerservice', $tplurl); goto fhmNG; pGPVM: echo json_encode($resArr); goto B60Np; QnCGp: $chatid = pdo_insertid(); goto gc9H5; TqHgn: pdo_insert(BEST_CHAT, $data); goto QnCGp; XiDoz: Gxof5: goto imCU0; Ohpef: lZvaw: goto ObxSz; BXRPt: $zhouji = date('w'); goto r8t_W; GN2b8: ekAfE: goto fMb0L; HReHD: if (!($guotime > $kefutplminute)) { goto jh7dA; } goto fO1r5; xMbQM: exit; goto tvT09; ZZsJM: $resArr['error'] = 1; goto kSJcm; DzR6v: JNdOV: goto Qv7Q3; iSK_L: $resArr['jqrtime'] = date('Y-m-d H:i:s', $jqrtime); goto RJwbW; mPKkm: $dataup_fanskefu['lastcon'] = $lastcon; goto vSuof; VNXOt: N1vju: goto RnRXX; DoMyM: $resArr['error'] = 1; goto W127V; FBoYi: $resArr['error'] = 1; goto w9upg; Erf_I: echo json_encode($resArr); goto I2vbD; y6upI: $tplcon = $this->guolv($tplcon); goto TqHgn; GKVCG: APfwG: goto QXpo0; KnZUI: goto Xd0P5; goto tH_dp; oJib7: $resArr['jqravatar'] = tomedia($cservice['thumb']); goto r19Iv; JWPrA: $data['avatar'] = $fanskefu['fansavatar']; goto o8bGT; qJ3kN: if (!($cservice['day4'] == 0)) { goto ekAfE; } goto FFN4Z; FBJsB: $otherfanskefus = pdo_fetchall('SELECT id,kefuopenid FROM ' . tablename(BEST_FANSKEFU) . " WHERE weid = {$_W['uniacid']} AND nowjd > 0 AND fansopenid = '{$openid}' AND kefuopenid != '{$cservice['content']}'"); goto SVziu; resap: echo json_encode($resArr); goto RQm6R; EQ3UZ: if ($zhouji == '5') { goto FHdC5; } goto o7Z4L; XAT6l: if ($cservice['iszx'] == 1) { goto SfGke; } goto yLr67; FcueQ: exit; goto bOv_Z; dXgSu: $datajqr['type'] = $zdhf['hftype'] == 0 || $zdhf['hftype'] == 3 ? 2 : 4; goto IzJRO; QspIx: d4Mec: goto Dqiam; qQvMc: bDm_g: goto nVtIj; UOW9k: S0dio: goto cguNz; Rjb_7: HDP0z: goto cJcUk; mdszJ: goto lZvaw; goto GOGE_; gNfn6: $resArr['msg'] = $notonlinemsg; goto pGPVM; b4HOK: pdo_update(BEST_FANSKEFU, $dataup_fanskefu, array("id" => $fanskefu['id'])); goto XNCfS; n6ucW: $dataup_fanskefu['lasttime'] = TIMESTAMP; goto b4HOK; WxCm5: if ($zhouji == '3') { goto d4Mec; } goto WQTVT; bOv_Z: J1q01: goto wNSKa; NrYxy: $regex = '@(?i)\\b((?:[a-z][\\w-]+:(?:/{1,3}|[a-z0-9%])|www\\d{0,3}[.]|[a-z0-9.\\-]+[.][a-z]{2,4}/)(?:[^\\s()<>]+|\\(([^\\s()<>]+|(\\([^\\s()<>]+\\)))*\\))+(?:\\(([^\\s()<>]+|(\\([^\\s()<>]+\\)))*\\)|[^\\s`!()\\[\\]{};:\'".,<>?]))@'; goto iVGan; iU3tu: $resArr['content'] = $this->doReplacecon($data['content'], $data['type']); goto vQJUO; Rj_el: $nowhour = intval(date('H', TIMESTAMP)); goto y0x3g; oZp61: $chatcontent = trim($_GPC['content']); goto QzN28; WKIcu: $nowhour = intval(date('H', TIMESTAMP)); goto RZjWE; Hxsii: $data['openid'] = $fanskefu['fansopenid']; goto cGxJl; r19Iv: $datajqr['weid'] = $_W['uniacid']; goto vJ4_X; aaqiV: echo json_encode($resArr); goto xMbQM; G1rvW: exit; goto DzR6v; VNWd6: if (!($zdhf['hftype'] == 0)) { goto ZwvZL; } goto RMEW4; YFeIa: echo json_encode($resArr); goto j4ML_; J99Mw: jh7dA: goto ls_kS; RJwbW: $resArr['hftype'] = $zdhf['hftype']; goto VNWd6; EzCXz: echo json_encode($resArr); goto ShbXq; RvdXT: if (!($cservice['day7'] == 0)) { goto pSEsN; } goto rlKdo; LBHjW: tR6p9: goto iaJS5; qiUXK: $resArr['error'] = 1; goto QEs9x; dB0kF: hoWrH: goto LZMc_; GaqcS: OlTUr: goto Ohpef; y0x3g: if (!($nowhour < $cservice['starthour'] || $nowhour + 1 > $cservice['endhour'])) { goto J1q01; } goto GFcz4; VzeIr: $resArr['jqrcontent'] = $datajqr['content'] = tomedia($zdhf['imgcon']); goto Rjb_7; REEuf: $datajqr['avatar'] = tomedia($cservice['thumb']); goto dXgSu; QzN28: $lastcon = preg_replace('/\\xEE[\\x80-\\xBF][\\x80-\\xBF]|\\xEF[\\x81-\\x83][\\x80-\\xBF]/', '[]', $chatcontent); goto JIIGn; R5IBb: $jqrtime = $data['time'] + 1; goto iSK_L; WJLIa: YgI9w: goto Iysjy; g6KTN: $dataup_fanskefu['jdtime'] = TIMESTAMP; goto FBJsB; FCe5t: $dataup_fanskefu['kefudel'] = 0; goto mPKkm; iquYB: $resArr['msg'] = $notonlinemsg; goto wt2Lz; W127V: $resArr['msg'] = ''; goto lQv3c; S2YOt: $resArr['error'] = 1; goto iquYB; pfJT1: $resArr['msg'] = $notonlinemsg; goto IhJcp; oRz9u: Nvxzl: goto YKG8m; ZZJBi: goto Ld_qp; goto sRIND; RMEW4: $datajqr['content'] = $zdhf['content']; goto NrYxy; MIgGW: if (!($cservice['day1'] == 0)) { goto OlTUr; } goto ZZsJM; iep1I: if (!($cservice['isrealzx'] == 0)) { goto ahzno; } goto vjUji; GOGE_: jj8Ju: goto MIgGW; HRqU2: if ($type == 3 || $type == 4) { goto igx06; } goto egvFl; SVRAG: $resArr['error'] = 1; goto SsaL7; dOM8t: SfGke: goto iep1I; rPUe0: $datajqr['toopenid'] = $data['openid']; goto oior6; q_9i8: FHdC5: goto E_1VD; vSuof: $dataup_fanskefu['msgtype'] = $type; goto n6ucW; ACAZM: $data['type'] = $type; goto HRqU2; WQTVT: if ($zhouji == '4') { goto r011z; } goto EQ3UZ; vjUji: $notonlinemsg = !empty($cservice['notonline']) ? $cservice['notonline'] : ''; goto S2YOt; WgvOw: $resArr['msg'] = ''; goto iU3tu; IhJcp: echo json_encode($resArr); goto Zsqui; dlqWw: $resArr['jqr'] = 1; goto R5IBb; XE1NN: $dataup_fanskefu['notread'] = $fanskefu['notread'] + 1; goto l6GSx; ls_kS: if (!($fanskefu['nowjd'] == 0)) { goto zlJ9c; } goto Nz2gh; lqjIB: ERANe: goto jXAlV; iVGan: preg_match_all($regex, $zdhf['content'], $array2); goto mBLEG; EyM9F: $resArr['msg'] = $notonlinemsg; goto YFeIa; Iysjy: $cservice = pdo_fetch('SELECT * FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = {$_W['uniacid']} AND ctype = 1 AND content = '{$_GPC['toopenid']}'"); goto XAT6l; Cpq0Z: global $_W, $_GPC; goto oZp61; Zw8p1: exit; goto shoeG; QXpo0: if (!($cservice['day6'] == 0)) { goto ERANe; } goto SVRAG; c6460: echo json_encode($resArr); goto FcueQ; B60Np: exit; goto VNXOt; lQv3c: echo json_encode($resArr); goto aSMWU; w9upg: $resArr['msg'] = $notonlinemsg; goto aaqiV; wNSKa: goto gmKAq; goto Mrqcu; XzEEH: Jl1Lx: goto oJib7; RZjWE: if (!($nowhour + 1 > $cservice['endhour'] && $nowhour < $cservice['starthour'])) { goto JNdOV; } goto yLHwd; rlKdo: $resArr['error'] = 1; goto djGij; egvFl: $tplcon = $data['content']; goto KnZUI; sRIND: r011z: goto qJ3kN; yLr67: if ($cservice['lingjie'] == 1) { goto FbD8a; } goto Rj_el; yLHwd: $notonlinemsg = !empty($cservice['notonline']) ? $cservice['notonline'] : ''; goto wDjW2; Qv7Q3: gmKAq: goto jZLwe; V49Ip: $data['fkid'] = intval($_GPC['fkid']); goto XzVS6; IgwUw: $data['weid'] = $_W['uniacid']; goto k1_PL; VNq8s: $resArr['error'] = 1; goto UHq_o; Cu0cg: zlJ9c: goto XE1NN; JwyMI: $datajqr['openid'] = trim($_GPC['toopenid']); goto rPUe0; cJcUk: if (!($zdhf['hftype'] == 3)) { goto Jl1Lx; } goto iALbv; ObxSz: i_bHF: goto V49Ip; oior6: $datajqr['time'] = $jqrtime; goto WjA09; ducH_: $tplcon = $data['nickname'] . ''; goto NVKeZ; djGij: $resArr['msg'] = $notonlinemsg; goto EzCXz; TllnB: goto sIZP_; goto NUE6F; RnRXX: srsNu: goto TllnB; SsaL7: $resArr['msg'] = $notonlinemsg; goto UOgvP; o7Z4L: if ($zhouji == '6') { goto APfwG; } goto mN_sm; Wq0yz: ZwvZL: goto KHJyy; VDP1v: $dataup_fanskefu['fansdel'] = 0; goto FCe5t; bnXbq: $guotime = TIMESTAMP - $fanskefu['lasttime']; goto HReHD; NVKeZ: Xd0P5: goto y6upI; mN_sm: if ($zhouji == '0') { goto iogLp; } goto FBoYi; DCoQb: goto srsNu; goto QspIx; ShbXq: exit; goto umSyW; WM_LQ: $data['content'] = $chatcontent; goto IgwUw; KFRH7: $data['time'] = TIMESTAMP; goto WM_LQ; jeVgw: echo json_encode($resArr); goto G1rvW; egofg: $dataup_fanskefu['wherefrom'] = 0; goto VDP1v; I2vbD: exit; goto XiDoz; nVtIj: if (!($cservice['isxingqi'] == 1)) { goto i_bHF; } goto AAasT; IzJRO: $datajqr['isjqr'] = 1; goto O69r2; O69r2: pdo_insert(BEST_CHAT, $datajqr); goto S0iOM; GFcz4: $notonlinemsg = !empty($cservice['notonline']) ? $cservice['notonline'] : ''; goto qiUXK; tvT09: goto hoWrH; goto GxfUD; jZLwe: goto bDm_g; goto dOM8t; JIIGn: if (!empty($chatcontent)) { goto YgI9w; } goto DoMyM; lhGPs: if (empty($zdhf)) { goto DlKwA; } goto dlqWw; yeS88: foreach ($array2[0] as $kk => $vv) { goto zGJB2; dLnKT: Gxvxu: goto CNI1Q; dKhQS: $zdhf['content'] = str_replace($vv, '<a href=\'' . $vvurl . '\'>' . $vv . '</a>', $zdhf['content']); goto eX430; zGJB2: if (empty($vv)) { goto oCTOb; } goto WQf1I; eX430: oCTOb: goto dLnKT; WQf1I: $vvurl = strstr($vv, 'http') ? $vv : 'http://' . $vv; goto dKhQS; CNI1Q: } goto ZOi9m; tH_dp: igx06: goto ducH_; l6GSx: $dataup_fanskefu['guanlinum'] = $fanskefu['guanlinum'] + 1; goto egofg; RQm6R: exit; goto Wep8j; jXAlV: xp2Ub: goto H6NTv; o8bGT: $data['toopenid'] = trim($_GPC['toopenid']); goto KFRH7; ZOi9m: ab4p0: goto LBHjW; UHq_o: $resArr['msg'] = $notonlinemsg; goto Erf_I; S0iOM: DlKwA: goto I3GId; vJ4_X: $datajqr['fkid'] = intval($_GPC['fkid']); goto JwyMI; XzVS6: $fanskefu = pdo_fetch('SELECT * FROM ' . tablename(BEST_FANSKEFU) . " WHERE weid = {$_W['uniacid']} AND id = {$data['fkid']}"); goto Hxsii; gc9H5: $zdhf = pdo_fetch('select * from ' . tablename(BEST_ZIDONGHUIFU) . " where weid = {$_W['uniacid']} AND ((title = '{$chatcontent}' AND type = 1) OR (INSTR('{$chatcontent}',title) AND type = 2)) ORDER BY paixu DESC"); goto lhGPs; fhmNG: $senddata = array("openid" => $data['toopenid'], "url" => $tplurl, "first" => $tplcon, "keyword1" => $data['nickname']); goto sCpZ2; Mf8c8: if ($zhouji == '2') { goto kD7gl; } goto WxCm5; XNCfS: $resArr['error'] = 0; goto WgvOw; Mrqcu: FbD8a: goto WKIcu; GxfUD: iogLp: goto RvdXT; Dqiam: if (!($cservice['day3'] == 0)) { goto N1vju; } goto lvMaQ; fO1r5: $tplurl = $this->gettpldomain() . 'app/' . str_replace('./', '', $this->createMobileUrl('servicechat', array("ssopenid" => $data['openid'], "toopenid" => $data['openid']))); goto M3CIq; SVziu: foreach ($otherfanskefus as $k => $v) { goto bKU3j; cMWnH: B_yMX: goto SbYXJ; bKU3j: $dataotherfk['nowjd'] = 0; goto QyS0k; QyS0k: $dataotherfk['jdtime'] = 0; goto X346T; X346T: pdo_update(BEST_FANSKEFU, $dataotherfk, array("id" => $v['id'])); goto cMWnH; SbYXJ: } goto oRz9u; vQJUO: $resArr['datetime'] = date('Y-m-d H:i:s', $data['time']); goto JhhUe; Zsqui: exit; goto GN2b8; YKG8m: $this->updatenowjdnum(); goto Cu0cg; rj9IT: $resArr['error'] = 1; goto EyM9F; iaJS5: $resArr['jqrcontent'] = $zdhf['content']; goto Wq0yz; X4v3Q: if (!($cservice['day2'] == 0)) { goto S0dio; } goto rj9IT; umSyW: pSEsN: goto dB0kF; kSJcm: $resArr['msg'] = $notonlinemsg; goto tUQ9k; mBLEG: if (empty($array2[0])) { goto tR6p9; } goto yeS88; H6NTv: goto FBSRH; goto q_9i8; Z8GxE: $resArr['jqrcontent'] = htmlspecialchars_decode($zdhf['allcon']); goto XzEEH; QEs9x: $resArr['msg'] = $notonlinemsg; goto c6460; ma0gm: exit; goto GaqcS; UOgvP: echo json_encode($resArr); goto SbZx5; j4ML_: exit; goto UOW9k; AAasT: $notonlinemsg = !empty($cservice['notonline']) ? $cservice['notonline'] : ''; goto BXRPt; lvMaQ: $resArr['error'] = 1; goto gNfn6; DPd5Q: $resArr['msg'] = $notonlinemsg; goto jeVgw; sCpZ2: $this->sendtplmsg($senddata); goto J99Mw; LZMc_: goto xp2Ub; goto GKVCG; fMb0L: Ld_qp: goto DCoQb; NUE6F: kD7gl: goto X4v3Q; aSMWU: exit; goto WJLIa; r8t_W: if ($zhouji == '1') { goto jj8Ju; } goto Mf8c8; cGxJl: $data['nickname'] = $fanskefu['fansnickname']; goto JWPrA; SbZx5: exit; goto lqjIB; FFN4Z: $resArr['error'] = 1; goto pfJT1; E_1VD: if (!($cservice['day5'] == 0)) { goto Gxof5; } goto VNq8s; I3GId: pdo_query('update ' . tablename(BEST_FANSKEFU) . ' set notread=notread+1,guanlinum=guanlinum+1,wherefrom=0 where id=:id', array(":id" => $data['fkid'])); goto hSo_o; tUQ9k: echo json_encode($resArr); goto ma0gm; hSo_o: $kefutplminute = $this->getmoduleconfig('kefutplminute'); goto bnXbq; k1_PL: $type = intval($_GPC['type']); goto ACAZM; KHJyy: if (!($zdhf['hftype'] == 2)) { goto HDP0z; } goto VzeIr; wDjW2: $resArr['error'] = 1; goto DPd5Q; JhhUe: $resArr['chatid'] = $chatid; goto resap; Wep8j: } public function gettpldomain() { goto A8y_T; Rbe15: $tpldomain = $this->getmoduleconfig('tpldomain'); goto rWrz7; rWrz7: return $tpldomain != '' ? $tpldomain : $_W['siteroot']; goto zDoKz; A8y_T: global $_W, $_GPC; goto Rbe15; zDoKz: } public function doMobileAddchatxcx() { goto XevQW; LDNBr: ANHOs: goto SfdGN; wYjDP: $msgtype = 'text'; goto jfgNq; m3qun: $resArr['error'] = 1; goto JQp9V; JjXyU: $data['gh_id'] = $fanskefu['gh_id']; goto SXTsG; XevQW: global $_W, $_GPC; goto JCXvk; pAqyj: a09Bh: goto oXeFu; O6MCu: $chatcontent = tomedia($chatcontent); goto SjNWB; RzVDV: if ($type == 2) { goto JV4Ep; } goto C1ThA; JnMyB: if (!($type == 2)) { goto ZUCxA; } goto wYjDP; EXDgB: echo json_encode($resArr); goto hEKc4; X9Rru: $data['weid'] = $_W['uniacid']; goto KSg_H; jfgNq: $dataup['lastcon'] = preg_replace('/\\xEE[\\x80-\\xBF][\\x80-\\xBF]|\\xEF[\\x81-\\x83][\\x80-\\xBF]/', '[]', $chatcontent); goto d9xD3; wqwZU: $dataup['msgtype'] = $msgtype; goto JYlVx; Q1328: $data['openid'] = $fanskefu['kefuopenid']; goto z2Inx; ASl97: if (!($addres['errcode'] == '40001')) { goto feXAf; } goto Ar5kG; sEXEI: if (!($type == 3)) { goto svNBJ; } goto Tdl9a; xqUJQ: XZebZ: goto C9ufw; EQx_7: if (!empty($chatcontent)) { goto vjMaG; } goto m3qun; hEKc4: exit; goto pAqyj; G4mtX: vjMaG: goto ZExoj; NlJM7: $addres = $this->addxcxchat2($fanskefu['fansopenid'], $chatcontent, $msgtype, $fanskefu['gh_id']); goto ASl97; StCbB: echo json_encode($resArr); goto hblbC; d9xD3: ZUCxA: goto sEXEI; MkyD1: feXAf: goto Iyrh_; Tdl9a: $msgtype = 'image'; goto O6MCu; Ar5kG: $addres = $this->addxcxchat2($fanskefu['fansopenid'], $chatcontent, $msgtype, $fanskefu['gh_id'], 1); goto MkyD1; vym3P: JV4Ep: goto nGGZG; SNhTp: $resArr['msg'] = $this->getwxerrormsg($addres); goto EXDgB; HXXp7: $chatcontent = trim($_GPC['content']); goto EQx_7; S87zy: $data['msgtype'] = $msgtype; goto ksHtw; KSg_H: $data['fkid'] = $fkid; goto S87zy; a_5Tl: exit; goto LHvXy; z2Inx: $data['toopenid'] = $fanskefu['fansopenid']; goto JjXyU; nGGZG: $resArr['content'] = '<div class="concon">' . $chatcontent . '</div>'; goto xqUJQ; JCXvk: $fkid = intval($_GPC['fkid']); goto GUnkH; ZExoj: $fanskefu = pdo_fetch('SELECT * FROM ' . tablename(BEST_XCXFANSKEFU) . " WHERE id = {$fkid}"); goto JnMyB; x7LFo: $data['content'] = $chatcontent; goto X9Rru; Zz0n_: $dataup['lasttime'] = $data['time']; goto wqwZU; SXTsG: $data['time'] = $addres['time']; goto x7LFo; JQp9V: $resArr['msg'] = ''; goto StCbB; ksHtw: pdo_insert(BEST_XCXCHAT, $data); goto Zz0n_; Iyrh_: if ($addres['errcode'] != '0') { goto ANHOs; } goto Q1328; rVWal: $resArr['msg'] = ''; goto Z1ACX; SjNWB: $dataup['lastcon'] = '[]'; goto WA2c6; C1ThA: $resArr['content'] = '<div class="concon"><img src="' . $chatcontent . '" class="sssbbb" /></div>'; goto avjXh; GUnkH: $type = intval($_GPC['type']); goto HXXp7; SfdGN: $resArr['error'] = 1; goto SNhTp; WA2c6: svNBJ: goto NlJM7; hblbC: exit; goto G4mtX; avjXh: goto XZebZ; goto vym3P; C9ufw: $resArr['error'] = 0; goto rVWal; SqtOE: echo json_encode($resArr); goto a_5Tl; JYlVx: pdo_update(BEST_XCXFANSKEFU, $dataup, array("id" => $fkid)); goto RzVDV; Z1ACX: $resArr['datetime'] = date('Y-m-d H:i:s', $data['time']); goto SqtOE; LHvXy: goto a09Bh; goto LDNBr; oXeFu: } public function addxcxchat2($touser, $content, $msgtype, $gh_id, $isnewtoken = 0) { goto Y8qa4; kEulT: exit; goto nzrx3; X12EJ: echo json_encode($resArr); goto vY2Jm; UKmIh: file_put_contents('../addons/cy163_customerservice/' . $fileName, $source); goto P0WAL; Be05l: $kefutokehures = $this->curl_post($url, $json); goto w2mZU; PWN2s: $imgres = $this->curl_post2($imgurl, '../addons/cy163_customerservice/' . $fileName); goto bBNmZ; SKYMa: DiXcq: goto z592U; GJnkv: if (!($msgtype == 'image')) { goto U6oE2; } goto LRqfZ; KTzMu: U6oE2: goto z979G; pn74L: $data = array("touser" => $touser, "msgtype" => "link", "link" => array("title" => $content['title'], "description" => $content['description'], "url" => $content['url'], "thumb_url" => $content['thumb_url'])); goto SKYMa; g3Mek: $access_token = $this->get_xcx_accessToken($xcx['appid'], $xcx['secret']); goto OZf7j; abfMF: return $kefutokehures; goto zPUyi; sPOkI: $data = array("touser" => $touser, "msgtype" => "text", "text" => array("content" => $content)); goto Z42BA; XZvdx: echo json_encode($resArr); goto kEulT; MlqLV: $dataup['guoqitime'] = $nowtime + 3600; goto eayLE; qJ_ql: $resArr['msg'] = 'AccessToken'; goto XZvdx; LNxTZ: $data = array("touser" => $touser, "msgtype" => "image", "image" => array("media_id" => $imgres['media_id'])); goto KTzMu; v40Mn: zC81b: goto ovmia; fwdv4: $resArr['error'] = 1; goto oGUq6; HEOYe: goto A6KQr; goto GiZZZ; mjoLD: $dataup['guoqitime'] = $nowtime + 3600; goto lhAqq; m1ThT: $xcx = pdo_fetch('SELECT * FROM ' . tablename(BEST_XCX) . " WHERE uniacid = {$_W['uniacid']} AND gh_id = '{$gh_id}'"); goto VswrL; w2mZU: $kefutokehures = json_decode($kefutokehures, true); goto uAL_h; llIfY: $dataup['access_token'] = $access_token; goto MlqLV; vY2Jm: exit; goto v40Mn; NldgV: $json = json_encode($data, JSON_UNESCAPED_UNICODE); goto Be05l; nzrx3: odYLf: goto llIfY; PbcEa: q_ASt: goto g3Mek; LRqfZ: $fileName = time() . '.jpg'; goto hks3s; hks3s: $source = file_get_contents($content); goto UKmIh; P0WAL: $imgurl = 'http://api.weixin.qq.com/cgi-bin/media/upload?access_token=' . $access_token . '&type=image'; goto PWN2s; k_VQB: $access_token = $xcx['access_token']; goto HEOYe; z979G: if (!($msgtype == 'link')) { goto DiXcq; } goto pn74L; z592U: $url = 'https://api.weixin.qq.com/cgi-bin/message/custom/send?access_token=' . $access_token; goto NldgV; lhAqq: pdo_update(BEST_XCX, $dataup, array("id" => $xcx['id'])); goto VzRuN; GiZZZ: aNwra: goto aG52n; uAL_h: $kefutokehures['time'] = $nowtime; goto abfMF; bBNmZ: unlink('../addons/cy163_customerservice/' . $fileName); goto LNxTZ; rB3Di: if (!($access_token == 'error')) { goto odYLf; } goto XU9nN; ZhAhL: if (!($msgtype == 'text')) { goto zcbga; } goto sPOkI; oGUq6: $resArr['msg'] = 'AccessToken'; goto X12EJ; LStXM: $nowtime = TIMESTAMP; goto m1ThT; Z42BA: zcbga: goto GJnkv; up7J3: if ($xcx['guoqitime'] < TIMESTAMP) { goto aNwra; } goto k_VQB; OVVGn: A6KQr: goto e2VQf; VswrL: if ($isnewtoken == 1) { goto q_ASt; } goto up7J3; Y8qa4: global $_GPC, $_W; goto LStXM; XU9nN: $resArr['error'] = 1; goto qJ_ql; eayLE: pdo_update(BEST_XCX, $dataup, array("id" => $xcx['id'])); goto OVVGn; e2VQf: goto bdNwD; goto PbcEa; VzRuN: bdNwD: goto ZhAhL; aG52n: $access_token = $this->get_xcx_accessToken($xcx['appid'], $xcx['secret']); goto rB3Di; OZf7j: if (!($access_token == 'error')) { goto zC81b; } goto fwdv4; ovmia: $dataup['access_token'] = $access_token; goto mjoLD; zPUyi: } public function get_xcx_accessToken($appid, $appsecret) { goto D_uZR; OQTNJ: return 'error'; goto GdgW1; GdgW1: goto Pm7mv; goto DIq2T; PdlU3: if ($res) { goto m19jp; } goto OQTNJ; DIq2T: m19jp: goto bnjuE; bnjuE: return $res['access_token']; goto F2f6w; F2f6w: Pm7mv: goto mEwZr; UOdzt: $result = $this->curl_get_https($url); goto AwM3F; AwM3F: $res = json_decode($result, true); goto PdlU3; D_uZR: $url = 'https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential&appid=' . $appid . '&secret=' . $appsecret; goto UOdzt; mEwZr: } public function curl_get_https($url) { goto tQj5j; kq10g: curl_setopt($curl, CURLOPT_URL, $url); goto yH6Fn; orTb6: curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, true); goto K1lNK; K1lNK: $tmpInfo = curl_exec($curl); goto E2n_e; Klw2a: curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false); goto orTb6; yH6Fn: curl_setopt($curl, CURLOPT_HEADER, 0); goto I9AyY; tQj5j: $curl = curl_init(); goto kq10g; I9AyY: curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1); goto Klw2a; V7i1v: return $tmpInfo; goto TU_cp; E2n_e: curl_close($curl); goto V7i1v; TU_cp: } public function getwxerrormsg($addres) { goto MB_aa; CsdKk: Rlacv: goto BCJij; b00vm: $errmsg = 'API '; goto J_TIW; PDCQe: if ($addres['errcode'] == '40001') { goto hqq16; } goto ATrMQ; Hrjb7: zKGuI: goto K9RUN; YoqQd: $errmsg = ' access_token  AppSecret  access_token  AppSecret '; goto EPLlD; Kuh8m: goto u0ecF; goto SK3w_; BCJij: $errmsg = ''; goto Kuh8m; SK3w_: hqq16: goto YoqQd; K9RUN: $errmsg = ''; goto eYHKC; zdUlU: $errmsg = $addres['errmsg']; goto R6axz; EPLlD: goto u0ecF; goto fw9uM; Yz4pv: u0ecF: goto jA_C5; kuFxe: $errmsg = ' OpenID OpenID  OpenID'; goto AWgER; dk34A: if ($addres['errcode'] == '40003') { goto bDFb7; } goto cjbZ6; EikiM: UjbGd: goto b00vm; MB_aa: if ($addres['errcode'] == '45047') { goto b6xYN; } goto lXwGi; e1_Ug: if ($addres['errcode'] == '45015') { goto zKGuI; } goto dk34A; ATrMQ: if ($addres['errcode'] == '-1') { goto eh2O9; } goto zdUlU; PFC1Z: $errmsg = ''; goto wEMBW; fw9uM: eh2O9: goto o3L_D; AWgER: goto u0ecF; goto CsdKk; FBLCd: b6xYN: goto PFC1Z; wEMBW: goto u0ecF; goto EikiM; eYHKC: goto u0ecF; goto PHfXv; o3L_D: $errmsg = ''; goto Yz4pv; R6axz: goto u0ecF; goto FBLCd; lXwGi: if ($addres['errcode'] == '48001') { goto UjbGd; } goto e1_Ug; cjbZ6: if ($addres['errcode'] == '40002') { goto Rlacv; } goto PDCQe; PHfXv: bDFb7: goto kuFxe; J_TIW: goto u0ecF; goto Hrjb7; jA_C5: return $errmsg; goto BrDGE; BrDGE: } public function curl_post($url, $data = array()) { goto upQ7f; mhBu2: if (curl_errno($ch)) { goto c83n9; } goto Jv25Y; QZoWj: return $rs; goto oECYi; upQ7f: $ch = curl_init(); goto l8gn1; K0Kkc: $rs = curl_exec($ch); goto mhBu2; Jv25Y: curl_close($ch); goto QZoWj; vO_Kn: curl_setopt($ch, CURLOPT_TIMEOUT, 20); goto K0Kkc; i4L50: curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE); goto gxqkH; zBa46: curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); goto ZgRhX; TqGSk: Yz33U: goto thbyO; W6HOM: CSUTx: goto zBa46; gxqkH: curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, FALSE); goto YovZJ; YovZJ: if (empty($data)) { goto CSUTx; } goto JNQpV; qp8S6: c83n9: goto jwroj; jwroj: $s = '{"success": false,"msg":"' . curl_error($ch) . '" }'; goto RlfeX; oECYi: goto Yz33U; goto qp8S6; l8gn1: curl_setopt($ch, CURLOPT_URL, $url); goto i4L50; ZgRhX: curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1); goto vO_Kn; mb0_B: curl_setopt($ch, CURLOPT_POSTFIELDS, $data); goto W6HOM; JNQpV: curl_setopt($ch, CURLOPT_POST, 1); goto mb0_B; RlfeX: return $s; goto TqGSk; thbyO: } public function doReplacecon($content, $msgtype, $istuwen = 0) { goto Idcgz; Idcgz: if (!($istuwen == 0)) { goto UdVum; } goto wG8o5; v8vuC: WlDhe: goto JuF2m; L_Yc8: B9ZwG: goto vankP; xz326: foreach ($array2[0] as $kk => $vv) { goto vyj9Z; YkVWM: dHYFx: goto Gvq3J; vyj9Z: if (empty($vv)) { goto fAc9W; } goto U05Lr; vjwaE: fAc9W: goto YkVWM; U05Lr: $content = str_replace($vv, '<a href=\'' . $vv . '\'>' . $vv . '</a>', $content); goto vjwaE; Gvq3J: } goto ko1iG; zOWkP: preg_match_all($regex, $content, $array2); goto YB1uZ; CDiSH: $content = '<img src="' . $content . '" />'; goto v8vuC; ko1iG: DA5kc: goto L_Yc8; YB1uZ: if (!(!empty($array2[0]) && ($msgtype == 1 || $msgtype == 2))) { goto B9ZwG; } goto xz326; b_CHW: if (!($msgtype == 3 || $msgtype == 4)) { goto WlDhe; } goto CDiSH; vankP: UdVum: goto b_CHW; wG8o5: $content = $this->guolv($content); goto yJhiZ; JuF2m: return htmlspecialchars_decode($content); goto Kakjs; yJhiZ: $regex = '@(?i)\\b((?:[a-z][\\w-]+:(?:/{1,3}|[a-z0-9%])|www\\d{0,3}[.]|[a-z0-9.\\-]+[.][a-z]{2,4}/)(?:[^\\s()<>]+|\\(([^\\s()<>]+|(\\([^\\s()<>]+\\)))*\\))+(?:\\(([^\\s()<>]+|(\\([^\\s()<>]+\\)))*\\)|[^\\s`!()\\[\\]{};:\'".,<>?]))@'; goto zOWkP; Kakjs: } public function guolv($content) { goto ABReD; nT3dg: foreach ($sensitivewordarr as $k => $v) { goto jlWdI; jlWdI: if (empty($v)) { goto itojW; } goto tneNy; JJWbX: itojW: goto gODc8; gODc8: ksyW3: goto jVSS_; tneNy: $content = str_replace($v, '***', $content); goto JJWbX; jVSS_: } goto n8RKa; byvNE: oP0DL: goto sr62L; CJscd: return $content; goto co5_O; sOqEI: if (empty($mingan)) { goto oP0DL; } goto N9mBD; N9mBD: $sensitivewordarr = explode('|', $mingan); goto nT3dg; ABReD: $mingan = $this->getmoduleconfig('mingan'); goto sOqEI; n8RKa: svjhl: goto byvNE; sr62L: $content = str_replace(' 
', '<br>', $content); goto CJscd; co5_O: } public function get_os() { goto hRgW1; XfY29: if (preg_match('/mac/i', $os)) { goto ig80P; } goto nAuVL; wtZTE: Ozrvc: goto MawRP; p_F3Q: TF3BH: goto h9_FS; n6G8y: DfTH4: goto goYhS; YyXgt: if (preg_match('/win/i', $os)) { goto Ozrvc; } goto XfY29; MawRP: $os = 'Windows'; goto jCBW0; ePJtT: return $os; goto p_F3Q; D_qsv: goto oRzpb; goto v0_p7; X5TSi: goto TF3BH; goto t02ky; A5Mwi: goto CJqbM; goto wtZTE; O0xB8: $os = $_SERVER['HTTP_USER_AGENT']; goto YyXgt; hRgW1: if (!empty($_SERVER['HTTP_USER_AGENT'])) { goto q0LLy; } goto L2C5a; t02ky: q0LLy: goto O0xB8; uMjMo: $os = 'BSD'; goto fVipP; hqZ79: $os = 'MAC'; goto gK6vM; EtIdm: pYC52: goto PRLLE; X4N13: JdN1m: goto NGai5; IJ69S: DUyqu: goto Ni3Xm; zJtPc: if (preg_match('/unix/i', $os)) { goto pYC52; } goto TndnE; L2C5a: return 'unknow'; goto X5TSi; TndnE: if (preg_match('/bsd/i', $os)) { goto UJN_j; } goto NA6Dz; NA6Dz: $os = 'Other'; goto D_qsv; jCBW0: CJqbM: goto ePJtT; NGai5: $os = 'Linux'; goto n6G8y; fVipP: oRzpb: goto RpWQW; Ni3Xm: goto DfTH4; goto X4N13; PRLLE: $os = 'Unix'; goto IJ69S; nAuVL: if (preg_match('/linux/i', $os)) { goto JdN1m; } goto zJtPc; v0_p7: UJN_j: goto uMjMo; RpWQW: goto DUyqu; goto EtIdm; goYhS: goto c380s; goto XvYU2; XvYU2: ig80P: goto hqZ79; gK6vM: c380s: goto A5Mwi; h9_FS: } public function browse_info() { goto v_xrf; f3dl2: gFkF_: goto xeKaK; TNZ_Z: AZqgN: goto ZGf_v; xeKaK: goto npSBE; goto UD5yl; EoeJ7: eSup9: goto raCVw; PKqJl: w1P1d: goto wkLHE; rWMoF: $br = 'Other'; goto N9GI0; UD5yl: NCsGj: goto NIsRy; jE1ly: xrafI: goto izYSu; izYSu: $br = $_SERVER['HTTP_USER_AGENT']; goto RvYOt; l5TNl: v9UK3: goto HtvU3; ZGf_v: goto v9UK3; goto UnyRN; UnyRN: WZgVI: goto S7wg7; B0knz: return 'unknow'; goto aYgEX; N9GI0: goto eSup9; goto BBYZo; wkLHE: $br = 'Safari'; goto f3dl2; Rzqyp: $br = 'Opera'; goto EoeJ7; ShmCm: if (preg_match('/Chrome/i', $br)) { goto NCsGj; } goto jFAGq; jFAGq: if (preg_match('/Safari/i', $br)) { goto w1P1d; } goto HQ36A; RvYOt: if (preg_match('/MSIE/i', $br)) { goto WZgVI; } goto OKYSB; NIsRy: $br = 'Chrome'; goto kuWdW; HQ36A: if (preg_match('/Opera/i', $br)) { goto yffKP; } goto rWMoF; OKYSB: if (preg_match('/Firefox/i', $br)) { goto PVb5b; } goto ShmCm; aYgEX: goto Xe4KQ; goto jE1ly; di8FL: $br = 'Firefox'; goto TNZ_Z; raCVw: goto gFkF_; goto PKqJl; v_xrf: if (!empty($_SERVER['HTTP_USER_AGENT'])) { goto xrafI; } goto B0knz; kuWdW: npSBE: goto jsE9L; IWFZv: Xe4KQ: goto EfATH; BBYZo: yffKP: goto Rzqyp; NFITQ: PVb5b: goto di8FL; S7wg7: $br = 'MSIE'; goto l5TNl; jsE9L: goto AZqgN; goto NFITQ; HtvU3: return $br; goto IWFZv; EfATH: } public function curl_post2($url = "", $path = "") { goto rFhqo; yqee_: curl_setopt($curl, CURLOPT_URL, $url); goto Onkpc; yAGQt: Csazs: goto kZ_SE; kZ_SE: curl_setopt($curl, CURLOPT_SAFE_UPLOAD, true); goto FtbDy; O5n0n: j38_y: goto yqee_; FtbDy: $data = array("media" => new CURLFile($path)); goto O5n0n; zab4W: $data = array("media" => '@' . $path); goto DoG3u; Bbqel: $res = json_decode($result, true); goto crfST; crfST: return $res; goto iewOg; GaRaW: curl_setopt($curl, CURLOPT_SAFE_UPLOAD, false); goto zab4W; cTeDz: curl_setopt($curl, CURLOPT_USERAGENT, 'TEST'); goto wnt2j; rFhqo: $curl = curl_init(); goto MCGBK; MCGBK: if (class_exists('CURLFile')) { goto Csazs; } goto GaRaW; DoG3u: goto j38_y; goto yAGQt; jq2Hq: curl_setopt($curl, CURLOPT_POSTFIELDS, $data); goto RSojY; Onkpc: curl_setopt($curl, CURLOPT_POST, 1); goto jq2Hq; RSojY: curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1); goto cTeDz; wnt2j: $result = curl_exec($curl); goto Bbqel; iewOg: } public function get_lang() { goto C3b78; ib8bS: if (preg_match('/zh/i', $lang)) { goto AF5xb; } goto PEVJn; FZvwZ: $lang = $_SERVER['HTTP_ACCEPT_LANGUAGE']; goto aLCbh; G09hI: return $lang; goto atbrH; EzY34: oa2e1: goto RuelN; Y5LIV: return 'unknow'; goto XCkuu; XCkuu: goto f0Zg2; goto hIh8r; C3b78: if (!empty($_SERVER['HTTP_ACCEPT_LANGUAGE'])) { goto So_TV; } goto Y5LIV; Ja54w: inmBf: goto G09hI; RuelN: goto inmBf; goto ik3Eh; atbrH: f0Zg2: goto KZ0Q_; PEVJn: $lang = 'English'; goto SyJV6; P8lAC: $lang = ''; goto Ja54w; aLCbh: $lang = substr($lang, 0, 5); goto GATro; ik3Eh: bNBML: goto P8lAC; KjmEI: AF5xb: goto FHnJk; SyJV6: goto oa2e1; goto KjmEI; GATro: if (preg_match('/zh-cn/i', $lang)) { goto bNBML; } goto ib8bS; FHnJk: $lang = ''; goto EzY34; hIh8r: So_TV: goto FZvwZ; KZ0Q_: } } ?>

Did this file decode correctly?

Original Code

<?php
 goto Tp1T1; ZQBpM: define('BEST_XCXFANSKEFU', 'messikefu_xcxfanskefu'); goto TOYId; zlZKh: define('BEST_CSERVICEGROUP', 'messikefu_cservicegroup'); goto VmR8F; cG0vp: define('BEST_BIAOQIAN', 'messikefu_biaoqian'); goto c28Zz; wFvla: define('BEST_XCXCSERVICE', 'messikefu_xcxcservice'); goto ZQBpM; VmR8F: define('BEST_FANSKEFU', 'messikefu_fanskefu'); goto i25uy; c28Zz: define('BEST_KUAIJIE', 'messikefu_kuaijie'); goto KrBlr; CSFwx: define('BEST_KEFUANDGROUP', 'messikefu_kefuandgroup'); goto cG0vp; hhIXC: define('BEST_CHAT', 'messikefu_chat'); goto yhWot; SVNcK: define('ROOT_PATH', IA_ROOT . '/addons/cy163_customerservice_plugin_p/'); goto M2dOk; KrBlr: define('BEST_XCX', 'messikefu_xcx'); goto wFvla; M2dOk: define('MD_ROOT', '../addons/cy163_customerservice_plugin_p/static'); goto iTKs7; iTKs7: define('MD_ROOT_Z', '../addons/cy163_customerservice/'); goto f7Mlg; yhWot: define('BEST_CSERVICE', 'messikefu_cservice'); goto zlZKh; iV3it: define('BEST_ZIDONGHUIFU', 'messikefu_zdhf'); goto Di985; R4voD: define('BEST_XCXAUTO', 'messikefu_xcxauto'); goto iV3it; TOYId: define('BEST_XCXCHAT', 'messikefu_xcxchat'); goto R4voD; i25uy: define('BEST_PINGJIA', 'messikefu_pingjia'); goto CSFwx; Tp1T1: defined('IN_IA') or exit('Access Denied'); goto SVNcK; f7Mlg: define('NEWSTATIC_ROOT', '../addons/cy163_customerservice/newstatic'); goto hhIXC; Di985: class Cy163_customerservice_plugin_pModuleSite extends WeModuleSite { public function doMobileKefulogin() { include_once ROOT_PATH . 'inc/mobile/kefulogin.php'; } public function doMobileKefucenter() { include_once ROOT_PATH . 'inc/mobile/kefucenter.php'; } public function doMobileFinishjd() { goto qnsFR; byqxt: goto Iz34a; goto fanYq; FuAqu: exit; goto PGs20; wRwtF: $isjd = intval($_GPC['isjd']); goto jPN7Z; B1_GL: $resArr['msg'] = ''; goto nIj_F; q4Ms3: Iz34a: goto JSYzd; XSVu1: if (empty($lastjd)) { goto Yz1ME; } goto X_5Zt; Zo1wC: $resArr['url'] = $this->createMobileUrl('kefucenter', array("isjd" => $isjd)); goto q4Ms3; qnsFR: global $_W, $_GPC; goto V41tY; x4Ieo: $dataupfk['nowjd'] = 0; goto qO_IP; fanYq: Yz1ME: goto Zo1wC; Fx6XW: $dataupkefu['nowjdnum'] = $cservice['nowjdnum'] - 1; goto FaSZ2; PkHnT: $cservice = pdo_fetch('SELECT * FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = {$_W['uniacid']} AND id = {$id}"); goto ryHyX; JSYzd: $resArr['error'] = 0; goto B1_GL; nIj_F: echo json_encode($resArr); goto FuAqu; V41tY: $fkid = intval($_GPC['fkid']); goto x4Ieo; FaSZ2: pdo_update(BEST_CSERVICE, $dataupkefu, array("id" => $cservice['id'])); goto wRwtF; qO_IP: $dataupfk['jdtime'] = 0; goto Gvu3I; Gvu3I: pdo_update(BEST_FANSKEFU, $dataupfk, array("id" => $fkid)); goto Yggk9; jPN7Z: $lastjd = pdo_fetchall('SELECT fansopenid FROM ' . tablename(BEST_FANSKEFU) . " WHERE weid = {$_W['uniacid']} AND kefuopenid = '{$cservice['content']}' AND nowjd = {$isjd} ORDER BY jdtime ASC LIMIT 1"); goto XSVu1; X_5Zt: $resArr['url'] = $this->createMobileUrl('kefucenter', array("toopenid" => $lastjd[0]['fansopenid'], "isjd" => $isjd)); goto byqxt; ryHyX: $dataupkefu['nowfkid'] = 0; goto Fx6XW; Yggk9: $id = intval($_GPC['id']); goto PkHnT; PGs20: } public function doMobilePcupload() { goto TsUWM; UE8jb: if (file_exists($targetName)) { goto ioeV4; } goto ipqRA; r23Um: if ($isqiniu == 3) { goto fKRay; } goto eiI_z; MANUv: KhD0P: goto MwBWH; CYswr: mXyM2: goto zzllR; bSI9X: $resarr['realimgurl'] = $randimgurl; goto pkOs5; wpgrF: $resarr['imgurl'] = tomedia($randimgurl); goto Sgeb7; G0_9R: MY50O: goto JmM0T; wv02x: o2zcY: goto xDlNv; BcZYk: $resarr['realimgurl'] = $randimgurl; goto FyggK; YMowd: $resarr['realimgurl'] = $randimgurl; goto wpgrF; pVrvo: qutA2: goto JB2on; ipqRA: $resarr['error'] = 1; goto sfbMP; JmM0T: $resarr['error'] = 1; goto ef_Ia; eiI_z: goto MBd4r; goto MANUv; iqo6B: $resarr['message'] = ''; goto RdlS4; nm4se: load()->func('file'); goto s11fL; M0UE3: $resarr['error'] = 0; goto yTjVw; X6zgc: goto mXyM2; goto LpCd2; fNIf2: $resarr['error'] = 1; goto drXCV; Sgeb7: $resarr['message'] = ''; goto PZvlI; LWcf2: $url = $_FILES['jUploaderFile']['tmp_name']; goto FzXhR; drXCV: $resarr['message'] = ''; goto fWcs3; vyWEV: die(json_encode($resarr)); goto X8f34; zzllR: echo json_encode($resarr, true); goto eBt53; gHzxI: fKRay: goto zbM6L; FyggK: $qiniuurl = $this->getmoduleconfig('qiniuurl'); goto csv_0; xDlNv: MBd4r: goto bSI9X; Gmctk: $isqiniu = $this->getmoduleconfig('isqiniu'); goto NbF_O; IqxK1: $targetName = '../attachment/' . $randimgurl; goto yMEvX; QxCMJ: goto lnytp; goto sjVhV; KckrK: if (file_exists($updir)) { goto qutA2; } goto znqJ4; s11fL: $remotestatus = file_remote_upload($randimgurl, true); goto Op29c; KV6jv: $resarr['message'] = ''; goto CYswr; YJOhf: goto fzOkT; goto G0_9R; TsUWM: global $_W, $_FILES, $_GPC; goto LWcf2; MwBWH: $remotestatus = $this->doQiuniu($randimgurl, true); goto VDQYF; ef_Ia: $resarr['message'] = ''; goto vyWEV; znqJ4: mkdir($updir, 0777, true); goto pVrvo; pkOs5: $resarr['imgurl'] = tomedia($randimgurl); goto KV6jv; RdlS4: die(json_encode($resarr)); goto YJOhf; sjVhV: L1cLn: goto fNIf2; Op29c: if (is_error($remotestatus)) { goto L1cLn; } goto YMowd; VieTK: $this->mkThumbnail($targetName, 640, null, $targetName); goto xDG5V; PZvlI: die(json_encode($resarr)); goto QxCMJ; Mb7oJ: goto MBd4r; goto gHzxI; LpCd2: ioeV4: goto M0UE3; fWcs3: die(json_encode($resarr)); goto KMs7F; yMEvX: move_uploaded_file($url, $targetName); goto UE8jb; yTjVw: $img_info = getimagesize($targetName); goto GKwTk; eBt53: exit; goto L2qR_; sfbMP: $resarr['message'] = ''; goto X6zgc; JB2on: $randimgurl = 'images/' . $_W['uniacid'] . '/' . date('Y', time()) . '/' . date('m', time()) . '/' . date('YmdHis') . rand(1000, 9999) . '.jpg'; goto IqxK1; csv_0: $resarr['imgurl'] = $qiniuurl . '/' . $randimgurl; goto iqo6B; xDG5V: u1Ta4: goto Gmctk; GKwTk: if (!($img_info[0] > 640)) { goto u1Ta4; } goto VieTK; X8f34: fzOkT: goto Mb7oJ; zbM6L: if (empty($_W['setting']['remote']['type'])) { goto o2zcY; } goto nm4se; FzXhR: $updir = '../attachment/images/' . $_W['uniacid'] . '/' . date('Y', time()) . '/' . date('m', time()) . '/'; goto KckrK; KMs7F: lnytp: goto wv02x; VDQYF: if (is_error($remotestatus)) { goto MY50O; } goto BcZYk; NbF_O: if ($isqiniu == 1) { goto KhD0P; } goto r23Um; L2qR_: } public function doMobileJietuupload() { goto R5FfB; lbFtq: if ($isqiniu == 3) { goto URD53; } goto UIUnD; n1AEE: Tzaug: goto Ie16P; Ie16P: $resarr['error'] = 1; goto R3NsF; R3NsF: $resarr['message'] = ''; goto gnUK1; UCbQO: $resarr['realimgurl'] = $randimgurl; goto I0voT; aGw7w: $resarr['realimgurl'] = $randimgurl; goto bies8; gnUK1: die(json_encode($resarr)); goto SbRvF; uyM5r: URD53: goto DdLW2; P6cOw: $resarr['realimgurl'] = $randimgurl; goto b7j0N; U1TMt: $base64_body = substr(strstr($base64_url, ','), 1); goto a0rLK; O0_q_: if (is_error($remotestatus)) { goto M4cRq; } goto P6cOw; Q5StC: $resarr['message'] = ''; goto Xpnu1; O34BM: $targetName = '../attachment/' . $randimgurl; goto oRry4; xuoKZ: die(json_encode($resarr)); goto eZjUx; bv2sX: GXVvA: goto xmoSv; iMry7: $base64_url = $_GPC['img']; goto U1TMt; b7j0N: $qiniuurl = $this->getmoduleconfig('qiniuurl'); goto NQBt1; JNx6U: goto VwKNV; goto bOI2e; aq9mu: if (is_error($remotestatus)) { goto Tzaug; } goto UCbQO; C476d: oEv7K: goto FXmgA; UIUnD: goto Bg3UF; goto g4P_2; rtojE: if (file_exists($updir)) { goto GXVvA; } goto z1UWV; mAH1k: goto CsHOc; goto pIfOu; U0LnR: echo json_encode($resarr, true); goto ehovE; SXMTE: $resarr['error'] = 1; goto Q5StC; bOI2e: B0vCv: goto ZvhiH; UijH1: $updir = '../attachment/images/' . $_W['uniacid'] . '/' . date('Y', time()) . '/' . date('m', time()) . '/'; goto rtojE; xP2m5: VwKNV: goto U0LnR; Xpnu1: die(json_encode($resarr)); goto LnKDk; JN2DY: $resarr['error'] = 1; goto kCA7z; SbRvF: VsX7A: goto C476d; Pum_u: die(json_encode($resarr)); goto mAH1k; DdLW2: if (empty($_W['setting']['remote']['type'])) { goto oEv7K; } goto h9CaL; xGQx3: $resarr['message'] = ''; goto xuoKZ; oRry4: file_put_contents($targetName, $base64_data); goto R3KcL; NQBt1: $resarr['imgurl'] = $qiniuurl . '/' . $randimgurl; goto Zs9Kp; h9CaL: load()->func('file'); goto Gbvj0; VFieY: $remotestatus = $this->doQiuniu($randimgurl, true); goto O0_q_; I0voT: $resarr['imgurl'] = tomedia($randimgurl); goto xGQx3; ehovE: exit; goto jGsWi; ZvhiH: $resarr['error'] = 0; goto okucX; xmoSv: $randimgurl = 'images/' . $_W['uniacid'] . '/' . date('Y', time()) . '/' . date('m', time()) . '/' . date('YmdHis') . rand(1000, 9999) . '.jpg'; goto O34BM; CFOKM: goto Bg3UF; goto uyM5r; DM81u: $resarr['message'] = ''; goto xP2m5; eZjUx: goto VsX7A; goto n1AEE; g4P_2: pC20T: goto VFieY; LnKDk: CsHOc: goto CFOKM; Zs9Kp: $resarr['message'] = ''; goto Pum_u; okucX: $img_info = getimagesize($targetName); goto WpQfR; rhAtD: $isqiniu = $this->getmoduleconfig('isqiniu'); goto HK350; Gbvj0: $remotestatus = file_remote_upload($randimgurl, true); goto aq9mu; a0rLK: $base64_data = base64_decode($base64_body); goto UijH1; FXmgA: Bg3UF: goto aGw7w; bies8: $resarr['imgurl'] = tomedia($randimgurl); goto DM81u; R5FfB: global $_W, $_GPC; goto iMry7; R3KcL: if (file_exists($targetName)) { goto B0vCv; } goto JN2DY; pIfOu: M4cRq: goto SXMTE; z1UWV: mkdir($updir, 0777, true); goto bv2sX; kCA7z: $resarr['message'] = ''; goto JNx6U; HK350: if ($isqiniu == 1) { goto pC20T; } goto lbFtq; KrxLi: $this->mkThumbnail($targetName, 640, null, $targetName); goto cNzQo; cNzQo: EpdKn: goto rhAtD; WpQfR: if (!($img_info[0] > 640)) { goto EpdKn; } goto KrxLi; jGsWi: } public function doQiuniu($filename, $auto_delete_local = true) { goto XZBTl; yZYQb: $uploadtoken = $auth->uploadToken($qiniubucket, $filename, 3600, $putpolicy); goto eUNzI; lbTHe: CSWqE: goto xKkeJ; jW_1l: die(json_encode($resarr)); goto lbTHe; UQqFI: $isqiniu = $this->getmoduleconfig('isqiniu'); goto i2YAb; zSvgW: load()->func('file'); goto HmAbW; Zl0bb: $resarr['error'] = 1; goto CCNIT; fjupm: file_delete($filename); goto liD4Y; Ho40V: $qiniusecretkey = $isqiniu == 1 ? $qiniusecretkey : $_W['setting']['remote']['qiniu']['secretkey']; goto pjL9w; CCNIT: $resarr['message'] = ''; goto jW_1l; pjL9w: $qiniubucket = $isqiniu == 1 ? $qiniubucket : $_W['setting']['remote']['qiniu']['bucket']; goto zSvgW; CM6UD: $uploadmgr = new Qiniu\Storage\UploadManager($config); goto jqjcS; i2YAb: $qiniuaccesskey = $this->getmoduleconfig('qiniuaccesskey'); goto EM_Sh; SnUu5: $qiniuaccesskey = $isqiniu == 1 ? $qiniuaccesskey : $_W['setting']['remote']['qiniu']['accesskey']; goto Ho40V; PPVkm: goto CSWqE; goto EhO6l; EhO6l: PzTUi: goto Zl0bb; EM_Sh: $qiniusecretkey = $this->getmoduleconfig('qiniusecretkey'); goto jkNYk; ax8Hd: if (!$auto_delete_local) { goto bunt0; } goto fjupm; sZTig: $auth = new Qiniu\Auth($qiniuaccesskey, $qiniusecretkey); goto EpNZQ; eUNzI: list($ret, $err) = $uploadmgr->putFile($uploadtoken, $filename, ATTACHMENT_ROOT . '/' . $filename); goto ax8Hd; jqjcS: $putpolicy = Qiniu\base64_urlSafeEncode(json_encode(array("scope" => $qiniubucket . ':' . $filename))); goto yZYQb; WbFeL: if ($err !== null) { goto PzTUi; } goto BDt5E; liD4Y: bunt0: goto WbFeL; EpNZQ: $config = new Qiniu\Config(); goto CM6UD; BDt5E: return true; goto PPVkm; jkNYk: $qiniubucket = $this->getmoduleconfig('qiniubucket'); goto SnUu5; HmAbW: require_once IA_ROOT . '/framework/library/qiniu/autoload.php'; goto sZTig; XZBTl: global $_W; goto UQqFI; xKkeJ: } public function mkThumbnail($src, $width = null, $height = null, $filename = null) { goto zwgHU; lTOWq: imagedestroy($src_img); goto i7wwC; AaOgb: return false; goto P2YZI; r8JY3: $height = $src_h * ($width / $src_w); goto mKGDX; M98Hu: xQ6_i: goto cPScg; Rhvs_: $imagefunc($dest_img); goto IevKJ; mKGDX: VzXiu: goto G2QHA; KhE0o: XYohh: goto ahxI0; CTqyh: if (!(isset($width) && $width <= 0)) { goto zNWrT; } goto FxSGm; eZybb: QW4wS: goto puTjY; IevKJ: goto xMBUi; goto eZybb; zt9sF: if (isset($width)) { goto xQ6_i; } goto ugz3n; VIkpL: xMBUi: goto lTOWq; oyxsm: imagecopyresampled($dest_img, $src_img, 0, 0, 0, 0, $width, $height, $src_w, $src_h); goto tdGzI; hlcZ8: if (!(isset($height) && $height <= 0)) { goto NHqX9; } goto AaOgb; tdGzI: $imagefunc = 'image' . $img_type; goto iIygr; ntnH_: zNWrT: goto hlcZ8; ugz3n: $width = $src_w * ($height / $src_h); goto M98Hu; FxSGm: return false; goto ntnH_; zwgHU: if (!(!isset($width) && !isset($height))) { goto v3klQ; } goto xv9xO; i7wwC: imagedestroy($dest_img); goto ZFYx9; vuqZD: $src_mime = $size['mime']; goto AsN9O; P2YZI: NHqX9: goto xJn0l; hbyCO: OVszw: goto GP4D_; puTjY: $imagefunc($dest_img, $filename); goto VIkpL; ZFYx9: return true; goto qrdrP; ahxI0: KJ5ok: goto zt9sF; xJn0l: $size = getimagesize($src); goto UAVco; UAVco: if ($size) { goto OVszw; } goto hxpfc; GP4D_: list($src_w, $src_h, $src_type) = $size; goto vuqZD; LhaIj: header('Content-Type: ' . $src_mime); goto Rhvs_; xv9xO: return false; goto Xb2BV; hxpfc: return false; goto hbyCO; Xb2BV: v3klQ: goto CTqyh; G2QHA: $imagecreatefunc = 'imagecreatefrom' . $img_type; goto XDK2_; AsN9O: switch ($src_type) { case 1: $img_type = 'gif'; goto KJ5ok; case 2: $img_type = 'jpeg'; goto KJ5ok; case 3: $img_type = 'png'; goto KJ5ok; case 15: $img_type = 'wbmp'; goto KJ5ok; default: return false; } goto KhE0o; fEBUi: $dest_img = imagecreatetruecolor($width, $height); goto oyxsm; iIygr: if ($filename) { goto QW4wS; } goto LhaIj; cPScg: if (isset($height)) { goto VzXiu; } goto r8JY3; XDK2_: $src_img = $imagecreatefunc($src); goto fEBUi; qrdrP: } public function getmoduleconfig($key) { goto qUAy8; qUAy8: global $_W, $_GPC; goto hKyyd; hKyyd: $setting = pdo_fetch('SELECT settings FROM ' . tablename('uni_account_modules') . " WHERE uniacid = {$_W['uniacid']} AND module = 'cy163_customerservice'"); goto PyFB_; yTVhT: return $settings[$key]; goto S1qIi; PyFB_: $settings = unserialize($setting['settings']); goto yTVhT; S1qIi: } public function doMobileDuvoice() { goto KxB74; rv3T9: $fkid = intval($_GPC['fkid']); goto VzIbl; Wr49O: $resarr['error'] = 0; goto l_Aul; Rmfx6: $openid = $_SESSION['openid']; goto bXmZi; bXmZi: $media_id = $_GPC['media_id']; goto rv3T9; cwEDX: pdo_update(BEST_CHAT, $dataup, array("id" => $chatres['id'])); goto dyOVS; z5ayY: if (!($chatres['openid'] != $openid)) { goto RJCiQ; } goto CndIc; CndIc: $dataup['hasyuyindu'] = 1; goto cwEDX; KxB74: global $_W, $_GPC; goto Rmfx6; dyOVS: RJCiQ: goto Wr49O; VzIbl: $chatres = pdo_fetch('SELECT * FROM ' . tablename(BEST_CHAT) . " WHERE weid = {$_W['uniacid']} AND content = '{$media_id}' AND fkid = {$fkid}"); goto z5ayY; l_Aul: die(json_encode($resarr)); goto lQcK8; lQcK8: } public function doMobileGetvoice() { goto V3lAb; VIPg_: pdo_update(BEST_CHAT, $dataup, array("id" => $chatres['id'])); goto Klhdo; mFZcd: $resarr['error'] = 1; goto mmbjA; JMkbF: $chatres = pdo_fetch('SELECT * FROM ' . tablename(BEST_CHAT) . " WHERE weid = {$_W['uniacid']} AND content = '{$media_id}' AND fkid = {$fkid}"); goto tfhb2; jEwwV: f72pl: goto qqs05; Mydzf: $resarr['msg'] = ''; goto SwFMK; GIFrS: $chatres = $chatres2; goto rO9Po; if8Zf: $url = 'http://file.api.weixin.qq.com/cgi-bin/media/get?access_token=' . $access_token . '&media_id=' . $media_id; goto BI_7G; f9Uow: $savemp3 = 'audios/' . $_W['uniacid'] . '/' . date('Y', time()) . '/' . date('m', time()) . '/' . date('YmdHis') . rand(1000, 9999) . '.mp3'; goto A9MBE; AGo3R: $qiniusecretkey = $this->getmoduleconfig('qiniusecretkey'); goto dPgbV; SLH1b: $fops = $fops . '|saveas/' . $putpolicy; goto f2m_w; k5bq5: die(json_encode($resarr)); goto D_Nxr; aW21x: $openid = $_SESSION['openid']; goto Iy4Ct; qlGjJ: LiBBe: goto bMfFi; jv1j9: $resarr['error'] = 1; goto bxoal; qqs05: $uploadtoken = $auth->uploadToken($qiniubucket, null, 3600, $policy); goto zn73V; WQjKK: $qiniuurl = $isqiniu == 1 ? $qiniuurl : $_W['setting']['remote']['qiniu']['url']; goto mEI46; hs9um: $resarr['msg'] = ''; goto oa_RL; eqh03: $media_id = $_GPC['media_id']; goto G7E00; V3lAb: global $_W, $_GPC; goto aW21x; RzMhX: $resarr['weidu'] = 1; goto nbdL8; dPgbV: $qiniubucket = $this->getmoduleconfig('qiniubucket'); goto yxBTI; C68kn: AT1cT: goto g3Soy; A8trk: qE2qx: goto Uo8sB; zn73V: list($ret, $err) = $uploadmgr->putFile($uploadtoken, $savemp3, $targetName); goto DP4T3; TMcLY: $dataup['hasyuyindu'] = 1; goto RzMhX; oa_RL: die(json_encode($resarr)); goto QRt2M; A9MBE: load()->func('file'); goto HzTAn; jQJtV: $qiniusecretkey = $isqiniu == 1 ? $qiniusecretkey : $_W['setting']['remote']['qiniu']['secretkey']; goto AAKnR; YpPVI: $dataup['content'] = $qiniuurl . '/' . $ret['key']; goto hFUNf; JaJuD: $resarr['error'] = 1; goto hs9um; ZPlAE: $chatid = intval($_GPC['chatid']); goto JMkbF; bMfFi: $policy = array("persistentOps" => $fops, "persistentPipeline" => $liedui); goto jEwwV; FXNWX: $resarr['error'] = 1; goto Mydzf; kjMaS: die(json_encode($resarr)); goto kFKgC; C_qnv: $resarr['msg'] = ''; goto qmgNj; c4hTY: sleep(5); goto P0ZZ1; AAKnR: $qiniubucket = $isqiniu == 1 ? $qiniubucket : $_W['setting']['remote']['qiniu']['bucket']; goto WQjKK; Mg2Dw: $access_token = $account_api->getAccessToken(); goto if8Zf; KrD1d: $randvoiceurl = 'audios/' . $_W['uniacid'] . '/' . date('Y', time()) . '/' . date('m', time()) . '/' . date('YmdHis') . rand(1000, 9999) . '.amr'; goto QzDu7; iyqVW: HhKXB: goto eqh03; HHfST: JmQwM: goto JaJuD; lfpJL: $resarr['error'] = 1; goto yLRvz; Klhdo: $resarr['error'] = 0; goto SLt0M; ctnIN: bikrR: goto klxJ_; Uo8sB: $account_api = WeAccount::create(); goto Mg2Dw; iIo_t: goto TWh7p; goto HHfST; f2m_w: $liedui = $this->getmoduleconfig('liedui'); goto OOcvO; bxoal: $resarr['msg'] = ''; goto k5bq5; BUi0u: if (file_exists($updir)) { goto hHkfI; } goto UrTjU; uGbCI: $qiniuaccesskey = $isqiniu == 1 ? $qiniuaccesskey : $_W['setting']['remote']['qiniu']['accesskey']; goto jQJtV; P1Si4: $fp = @fopen($targetName, 'wb'); goto mHyjk; wpRrj: hHkfI: goto KrD1d; jhBrl: $policy = array("persistentOps" => $fops); goto OfySr; mHyjk: @fwrite($fp, $response['content']); goto gv0cU; hP4xC: if (!($chatres['mp3du'] == 1)) { goto bikrR; } goto FXNWX; mEI46: if (!($isqiniu == 0 || $qiniuaccesskey == '' || $qiniusecretkey == '' || $qiniubucket == '')) { goto HhKXB; } goto an4qk; tfhb2: if (!empty($chatres)) { goto Cu1G5; } goto gKjRD; qmgNj: die(json_encode($resarr)); goto iyqVW; QzDu7: $targetName = '../attachment/' . $randvoiceurl; goto P1Si4; D_Nxr: YPfYX: goto GIFrS; mmbjA: $resarr['msg'] = ", : {$result['errcode']}, : {$result['errmsg']}"; goto hAWfJ; gKjRD: $chatres2 = pdo_fetch('SELECT * FROM ' . tablename(BEST_CHAT) . " WHERE weid = {$_W['uniacid']} AND id = {$chatid}"); goto apHJT; nbdL8: yAznq: goto nz5H7; qsbs9: $putpolicy = Qiniu\base64_urlSafeEncode($qiniubucket . ':' . $savemp3); goto yJDZY; QDdoV: pdo_update(BEST_CHAT, array("mp3du" => 1), array("id" => $chatres['id'])); goto c4hTY; GyZV8: if (!is_error($response)) { goto y9VTD; } goto lfpJL; rO9Po: Cu1G5: goto hP4xC; UrTjU: mkdir($updir, 0777, true); goto wpRrj; BI_7G: $response = ihttp_get($url); goto GyZV8; SQMDP: $uploadmgr = new Qiniu\Storage\UploadManager($config); goto qsbs9; yF4PK: $resarr['msg'] = ''; goto u_Y0t; kFKgC: y9VTD: goto fjMfY; yxBTI: $qiniuurl = $this->getmoduleconfig('qiniuurl'); goto uGbCI; SwFMK: die(json_encode($resarr)); goto ctnIN; HzTAn: require_once IA_ROOT . '/framework/library/qiniu/autoload.php'; goto m1Rl5; u_Y0t: die(json_encode($resarr)); goto iIo_t; L9qLj: $resarr['voicefile'] = $chatres['content']; goto l4nqc; jvUvz: if (!empty($liedui)) { goto LiBBe; } goto jhBrl; P0ZZ1: file_delete($randvoiceurl); goto YpPVI; o3sR_: if (empty($result['errcode'])) { goto AT1cT; } goto mFZcd; Qx34h: $config = new Qiniu\Config(); goto SQMDP; klxJ_: if (!(strpos($chatres['content'], '.mp3') !== false)) { goto qE2qx; } goto xTVBQ; nz5H7: $dataup['mp3du'] = 0; goto VIPg_; gv0cU: @fclose($fp); goto f9Uow; OOcvO: $liedui = empty($liedui) ? '' : $liedui; goto jvUvz; l4nqc: die(json_encode($resarr)); goto A8trk; SLt0M: $resarr['voicefile'] = $qiniuurl . '/' . $ret['key']; goto yF4PK; xTVBQ: $resarr['error'] = 0; goto L9qLj; yJDZY: $fops = 'avthumb/mp3/ab/320k/ar/44100/acodec/libmp3lame'; goto SLH1b; QRt2M: TWh7p: goto Fq_HP; Iy4Ct: load()->func('communication'); goto Lqbee; hAWfJ: die(json_encode($resarr)); goto C68kn; yLRvz: $resarr['msg'] = ", : {$response['message']}"; goto kjMaS; an4qk: $resarr['error'] = 1; goto C_qnv; DP4T3: if ($err !== null) { goto JmQwM; } goto QDdoV; m1Rl5: $auth = new Qiniu\Auth($qiniuaccesskey, $qiniusecretkey); goto Qx34h; OfySr: goto f72pl; goto qlGjJ; fjMfY: $result = @json_decode($response['content'], true); goto o3sR_; Lqbee: $isqiniu = $this->getmoduleconfig('isqiniu'); goto Tpdzh; hFUNf: if (!($chatres['openid'] != $openid)) { goto yAznq; } goto TMcLY; g3Soy: $updir = '../attachment/audios/' . $_W['uniacid'] . '/' . date('Y', time()) . '/' . date('m', time()) . '/'; goto BUi0u; Tpdzh: $qiniuaccesskey = $this->getmoduleconfig('qiniuaccesskey'); goto AGo3R; G7E00: $fkid = intval($_GPC['fkid']); goto ZPlAE; apHJT: if (!empty($chatres2)) { goto YPfYX; } goto jv1j9; Fq_HP: } public function doWebQianru() { goto pc2ux; CYUCA: g8I7S: goto Afa4b; i3L5C: message('', referer(), 'success'); goto U7b0h; BvXdO: $operation = !empty($_GPC['op']) ? $_GPC['op'] : 'display'; goto uMAHl; Afa4b: $id = intval($_GPC['id']); goto erYfl; mFiAy: foreach ($cservicelist as $k => $v) { goto t6YIU; TqhZ1: $cservicelist[$k]['scripthtml2'] = htmlentities('<a href="' . $scripturl2 . '" style="z-index:10001;position:absolute;right:' . $qrset['qrright2'] . 'px;bottom:' . $qrset['qrbottom2'] . 'px;"><img style="height:auto;width:' . $qrset['qrwidth2'] . 'px;" src="' . tomedia($qrset['qrphonetu']) . '" /></a>'); goto sWXjM; uomXi: $cservicelist[$k]['scripthtml'] = htmlspecialchars($scripthtml); goto KxvP3; lJ43B: lF9OE: goto jQN_3; sWXjM: o2SvA: goto lJ43B; LQqD3: if (!empty($qrset)) { goto lu3C_; } goto CzvWy; gu6b6: goto o2SvA; goto bunRE; bunRE: lu3C_: goto gK01H; Z9dZh: $cservicelist[$k]['scripthtml2'] = ''; goto gu6b6; P743b: $cservicelist[$k]['qrset'] = $qrset; goto nvmTi; CzvWy: $cservicelist[$k]['scripthtml'] = ''; goto Z9dZh; t6YIU: $qrset = unserialize($v['qrmsg']); goto P743b; gK01H: $scripthtml = '<script type="text/javascript" src="' . $_W['siteroot'] . 'addons/cy163_customerservice_plugin_p/static/qianru.js"></script>
									<script type="text/javascript">
										document.getElementById("kfiframe").src="' . $scripturl . '";
										var xfkefu = document.getElementById("xfkefu");
										xfkefu.style.background = "' . $qrset['qrsetbgcolor'] . '";
										xfkefu.style.color = "' . $qrset['qrsettextcolor'] . '";
										xfkefu.innerText = "' . $qrset['qrsettext'] . '";
										xfkefu.style.fontSize = "' . $qrset['qrsettextsize'] . 'px";
										xfkefu.style.lineHeight = xfkefu.style.paddingTop = xfkefu.style.paddingBottom = "' . $qrset['qrsetlineheight'] . 'px";
										xfkefu.style.width = "' . $qrset['qrwidth'] . 'px";
										xfkefu.style.bottom = "' . $qrset['qrbottom'] . 'px";
										xfkefu.style.right = "' . $qrset['qrright'] . 'px";
									</script>
									'; goto uomXi; KxvP3: $scripturl2 = $_W['siteroot'] . 'app/index.php?i=' . $_W['uniacid'] . '&c=entry&do=chat&m=cy163_customerservice&toopenid=' . $v['content']; goto TqhZ1; nvmTi: $scripturl = $_W['siteroot'] . 'app/index.php?i=' . $_W['uniacid'] . '&c=entry&do=index&m=cy163_customerservice_plugin_p&toopenid=' . $v['content']; goto LQqD3; jQN_3: } goto oS6sB; ZyVaB: if ($operation == 'qrset') { goto g8I7S; } goto oa9xg; N9PBO: $cservicelist = pdo_fetchall('SELECT * FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = '{$_W['uniacid']}' AND ctype = 1 ORDER BY displayorder ASC"); goto mFiAy; oS6sB: sxv3F: goto rF4gY; BoMQA: pdo_update(BEST_CSERVICE, $data, array("id" => $id)); goto i3L5C; TDEjg: w54rl: goto N9PBO; pc2ux: global $_GPC, $_W; goto BvXdO; fuXEg: include $this->template('web/qianru'); goto AiCQm; uMAHl: if ($operation == 'display') { goto w54rl; } goto ZyVaB; rF4gY: goto bdt4Y; goto CYUCA; erYfl: $qrset = array("qrsetbgcolor" => trim($_GPC['qrsetbgcolor']), "qrsettextcolor" => trim($_GPC['qrsettextcolor']), "qrsettext" => trim($_GPC['qrsettext']), "qrsettextsize" => intval($_GPC['qrsettextsize']), "qrwidth" => intval($_GPC['qrwidth']), "qrbottom" => intval($_GPC['qrbottom']), "qrright" => intval($_GPC['qrright']), "qrsetlineheight" => intval($_GPC['qrsetlineheight']), "qrphonetu" => trim($_GPC['qrphonetu']), "qrbottom2" => intval($_GPC['qrbottom2']), "qrright2" => intval($_GPC['qrright2']), "qrwidth2" => intval($_GPC['qrwidth2'])); goto ImSig; oa9xg: goto bdt4Y; goto TDEjg; ImSig: $data['qrmsg'] = serialize($qrset); goto BoMQA; U7b0h: bdt4Y: goto fuXEg; AiCQm: } public function doWebCservice() { goto Y2HyS; OVoYc: if ($operation == 'display') { goto BJ3aK; } goto p10uS; HxZFv: tfS5Y: goto PelGc; gjGBm: $data['pwd'] = sha1($pwd); goto gv2lh; vkQG6: $user = trim($_GPC['user']); goto F4Urg; kuGe1: goto rAGm9; goto HxZFv; ux0S4: $cservicelist = pdo_fetchall('SELECT * FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = '{$_W['uniacid']}' AND ctype = 1 ORDER BY displayorder ASC"); goto fWIuB; nxIlM: echo json_encode($resArr); goto lQ6To; x9z3n: $resArr['error'] = 0; goto muZRv; vJrSX: if ($operation == 'changepwd') { goto vtIIg; } goto DZrWL; X0TAV: echo json_encode($resArr); goto ftuh0; iQNdj: $resArr['error'] = 1; goto gzN4P; dpxGh: echo json_encode($resArr); goto lse9n; lse9n: exit; goto Eg1Nd; fsv6m: $id = intval($_GPC['id']); goto GNE8C; GCZ3W: JTjrR: goto VeBLQ; gzN4P: $resArr['msg'] = ''; goto i6xW6; fWIuB: include $this->template('web/cservice'); goto kuGe1; m9Ubv: $resArr['msg'] = ''; goto LWc4f; y3_XX: yuLWa: goto U0CQa; MlfYh: $resArr['error'] = 1; goto sl3jJ; DZrWL: goto rAGm9; goto AHW4e; Wmi7G: if (!empty($pwd)) { goto vudYj; } goto F197c; jH8VT: $resArr['error'] = 0; goto AsVa6; oR82H: echo json_encode($resArr); goto UnW89; AHW4e: BJ3aK: goto ux0S4; AnDJO: $resArr['error'] = 1; goto m9Ubv; Eg1Nd: vudYj: goto cgAfQ; AsVa6: $resArr['msg'] = '' . $cservice['name'] . ''; goto X0TAV; DpDIN: $operation = !empty($_GPC['op']) ? $_GPC['op'] : 'display'; goto OVoYc; eiYpl: exit; goto y3_XX; nMvkL: goto rAGm9; goto gH1ku; gH1ku: vtIIg: goto fsv6m; zPphY: echo json_encode($resArr); goto Y4oEe; muZRv: $resArr['msg'] = '' . $cservice['name'] . ''; goto zPphY; PelGc: $id = intval($_GPC['id']); goto vkQG6; Y4oEe: exit; goto nMvkL; Vnfkn: $resArr['error'] = 1; goto il_w2; nrG65: Zlg0o: goto gjGBm; Y2HyS: global $_GPC, $_W; goto DpDIN; GNE8C: $pwd = trim($_GPC['pwd']); goto Wmi7G; sl3jJ: $resArr['msg'] = ''; goto nxIlM; VeBLQ: $data['username'] = $user; goto yiy_K; WEXTq: if (!empty($cservice)) { goto JTjrR; } goto AnDJO; F197c: $resArr['error'] = 1; goto NPK_R; ftuh0: exit; goto LuJ8M; aTF6q: if (!empty($cservice)) { goto Zlg0o; } goto MlfYh; zBun2: exit; goto GCZ3W; p10uS: if ($operation == 'changeuser') { goto tfS5Y; } goto vJrSX; gv2lh: pdo_update(BEST_CSERVICE, $data, array("id" => $id)); goto jH8VT; O5vpL: Kqwg0: goto ziy65; LWc4f: echo json_encode($resArr); goto zBun2; LuJ8M: rAGm9: goto WhRX7; yiy_K: pdo_update(BEST_CSERVICE, $data, array("id" => $id)); goto x9z3n; lQ6To: exit; goto nrG65; sZAW4: if (empty($hasuser)) { goto yuLWa; } goto iQNdj; U0CQa: $cservice = pdo_fetch('SELECT * FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = '{$_W['uniacid']}' AND id= {$id} AND ctype = 1"); goto WEXTq; cgAfQ: $cservice = pdo_fetch('SELECT * FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = '{$_W['uniacid']}' AND id= {$id} AND ctype = 1"); goto aTF6q; NPK_R: $resArr['msg'] = ''; goto dpxGh; F4Urg: if (!empty($user)) { goto Kqwg0; } goto Vnfkn; i6xW6: echo json_encode($resArr); goto eiYpl; UnW89: exit; goto O5vpL; il_w2: $resArr['msg'] = ''; goto oR82H; ziy65: $hasuser = pdo_fetch('SELECT id FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = '{$_W['uniacid']}' AND username = '{$user}' AND ctype = 1"); goto sZAW4; WhRX7: } public function doWebCgroup() { goto SEdt0; TTbgI: $cservicegrouplist = pdo_fetchall('SELECT * FROM ' . tablename(BEST_CSERVICEGROUP) . " WHERE weid = {$_W['uniacid']} ORDER BY displayorder ASC"); goto ZHsTI; ZHsTI: foreach ($cservicegrouplist as $k => $v) { $cservicegrouplist[$k]['servicegroupurl'] = $_W['siteroot'] . 'app/' . str_replace('./', '', $this->createMobileUrl('index', array("groupid" => $v['id']))); FeVrH: } goto qp7Hc; PRlye: include $this->template('web/cgroup'); goto IXCD2; qp7Hc: uwEN1: goto PRlye; SEdt0: global $_W, $_GPC; goto TTbgI; IXCD2: } public function doMobileIndex() { goto K1ylF; UikHS: Kow9k: goto vO3fV; bfzZj: $fangkearr = array("lang" => $this->get_lang(), "browse" => $this->browse_info(), "os" => $this->get_os(), "ip" => $_W['clientip'], "laiyuan" => $_SERVER['HTTP_REFERER'], "latitude" => $ipres['result']['location']['lat'], "longitude" => $ipres['result']['location']['lng'], "nation" => $ipres['result']['ad_info']['nation'], "province" => $ipres['result']['ad_info']['province'], "city" => $ipres['result']['ad_info']['city'], "district" => $ipres['result']['ad_info']['district'], "gzhname" => $_W['account']['name']); goto A6DBr; k4vT8: ouzN3: goto d2CnO; vRDFN: pzeYX: goto PSNuA; u0lEG: M8bjX: goto w0H0f; l73vh: foreach ($chatcon as $k => $v) { goto YSel7; VDT1Y: $chatcon[$k]['time'] = $v['time']; goto pAmUc; pAmUc: Wu4J1: goto lC224; bTm3f: Y3Gca: goto IJzfk; VuiQM: $regex = '@(?i)\\b((?:[a-z][\\w-]+:(?:/{1,3}|[a-z0-9%])|www\\d{0,3}[.]|[a-z0-9.\\-]+[.][a-z]{2,4}/)(?:[^\\s()<>]+|\\(([^\\s()<>]+|(\\([^\\s()<>]+\\)))*\\))+(?:\\(([^\\s()<>]+|(\\([^\\s()<>]+\\)))*\\)|[^\\s`!()\\[\\]{};:\'".,<>?]))@'; goto v2AJ6; ENaLd: mu63d: goto bTm3f; LY1T8: foreach ($array2[0] as $kk => $vv) { goto e1wsr; R1tbu: $chatcon[$k]['content'] = str_replace($vv, '<a href=\'' . $vv . '\'>' . $vv . '</a>', $chatcon[$k]['content']); goto SFqCY; SFqCY: uT62j: goto fMzBz; fMzBz: VB97u: goto Krnin; e1wsr: if (empty($vv)) { goto uT62j; } goto R1tbu; Krnin: } goto Sh3Lz; Sh3Lz: yAejO: goto ENaLd; lC224: $chatcontime = $v['time']; goto ORjYb; YSel7: if ($v['time'] - $chatcontime > 7200) { goto a3rkL; } goto jW4AI; ORjYb: $chatcon[$k]['content'] = preg_replace('/\\xEE[\\x80-\\xBF][\\x80-\\xBF]|\\xEF[\\x81-\\x83][\\x80-\\xBF]/', '[]', $v['content']); goto dtFC0; D5t4q: if (!(!empty($array2[0]) && ($v['type'] == 1 || $v['type'] == 2))) { goto mu63d; } goto LY1T8; jW4AI: $chatcon[$k]['time'] = ''; goto VE_2r; v2AJ6: preg_match_all($regex, $chatcon[$k]['content'], $array2); goto D5t4q; qs_p8: a3rkL: goto VDT1Y; VE_2r: goto Wu4J1; goto qs_p8; dtFC0: $chatcon[$k]['content'] = $this->guolv($chatcon[$k]['content']); goto VuiQM; IJzfk: } goto JFm28; d2CnO: $fkid = $hasfanskefu['id']; goto IsTBB; JFm28: wGfgn: goto pmfbM; ep2iE: $datafanskefu['fansopenid'] = $openid; goto F1cQQ; vO3fV: $chatcon = pdo_fetchall('SELECT * FROM ' . tablename(BEST_CHAT) . " WHERE fkid = {$hasfanskefu['id']} AND weid = {$_W['uniacid']} AND type != 5 AND type != 6 ORDER BY time ASC"); goto pGRS7; bQsgE: $ipurl = 'https://apis.map.qq.com/ws/location/v1/ip?ip=' . $_W['clientip'] . '&key=' . $mapkey; goto r8Hnj; aB8HA: $condition .= ' AND ((day6 = 1 AND isxingqi = 1) OR isxingqi = 0))'; goto UWohe; pGRS7: $chatcontime = 0; goto l73vh; y9a6R: $kefuids = array(0); goto qT_xG; fPXkQ: $ipres = json_decode($ipres, true); goto A2gj9; kdZ_a: $datafanskefu['fansnickname'] = ''; goto dnMUc; Ocp_N: $ipres = file_get_contents($ipurl); goto Jxo8r; Gp4IH: goto kyoKS; goto Ia6T5; dFKUq: goto qaUOV; goto CTSDw; shG19: pdo_update(BEST_FANSKEFU, $datafanskefuup, array("id" => $fkid)); goto GI5RH; CTSDw: IfMbv: goto HraMZ; Sbh3Y: $ipurl = 'https://apis.map.qq.com/ws/location/v1/ip?ip=' . $_W['clientip'] . '&key=' . $mapkey; goto vAH7x; AoBXV: $nowhour = intval(date('H', TIMESTAMP)); goto mcwsp; IjweE: $longitude = $ipres['result']['location']['lng'] . random(4, 1); goto rchsg; GNzN4: if (!($zhouji == '1')) { goto FihFC; } goto OfskB; mesm9: if ($suiji == 1) { goto jsoyT; } goto ibCWZ; oF1Kc: $openid = md5($jiamistr); goto Ys6Vw; TAU8p: $orderby = ' ORDER BY rand()'; goto B3l1x; II3Mz: foreach ($array2[0] as $kk => $vv) { goto QtyVG; T0UA0: $cservice['autoreply'] = str_replace($vv, '<a href=\'' . $vv . '\'>' . $vv . '</a>', $cservice['autoreply']); goto TRy_y; TRy_y: tf7sz: goto mtwaJ; mtwaJ: yp_j1: goto UQ0Xl; QtyVG: if (empty($vv)) { goto tf7sz; } goto T0UA0; UQ0Xl: } goto Y2NyU; iYdC7: nA3lK: goto bIC0z; uhURu: $nowhour = intval(date('H', TIMESTAMP)); goto gbt16; RcjRP: $cservice = pdo_fetch('SELECT * FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = {$_W['uniacid']} AND ctype = 1 AND content = '{$toopenid}'"); goto Nu2J4; ckOP6: $condition .= ' AND ((day3 = 1 AND isxingqi = 1) OR isxingqi = 0))'; goto KrVZj; azQoA: UqazJ: goto UikHS; vAH7x: $ipres = file_get_contents($ipurl); goto fPXkQ; r0_vZ: $jiamistr = $this->get_lang() . $this->browse_info() . $this->get_os() . $latitude . $longitude; goto oF1Kc; So2Ao: if (empty($array2[0])) { goto UqazJ; } goto II3Mz; Rj_dI: if (!empty($cservicegroup)) { goto iHlmL; } goto u4QQU; ibyJp: $datafanskefuup['fangke'] = serialize($fangkearr); goto hW4Zk; Fo4eC: $datafanskefu['fansavatar'] = tomedia($defaultavatar); goto kdZ_a; Ia6T5: brtzz: goto zA3Kk; ZMUDJ: $fangkearr = unserialize($hasfanskefu['fangke']); goto QtWdq; SLECI: $condition .= ' AND ((day2 = 1 AND isxingqi = 1) OR isxingqi = 0))'; goto AHSWp; lXarb: goto zuMSi; goto DuR8R; pSWC8: if (!empty($cservicegroup)) { goto brtzz; } goto AoBXV; fbXoZ: $cservicelist = pdo_fetchall('SELECT * FROM ' . tablename(BEST_CSERVICE) . ' WHERE ' . $condition . $orderby); goto Rj_dI; DuR8R: jsoyT: goto TAU8p; dnMUc: $datafanskefu['kefuavatar'] = tomedia($cservice['thumb']); goto s1YN0; Ys6Vw: $toopenid = trim($_GPC['toopenid']); goto lwYtA; gzzMu: $condition .= ' AND ((day4 = 1 AND isxingqi = 1) OR isxingqi = 0))'; goto iMVgQ; C0Z8i: include $this->template('pcchat'); goto HL0TJ; Y2NyU: bMG2h: goto azQoA; uol_S: $condition = "weid = {$_W['uniacid']} AND ctype = 1 AND ((iszx = 0 AND (
					(lingjie = 0 AND endhour >= {$nowhouradd} AND starthour <= {$nowhour}) OR 
					(lingjie = 1 AND (starthour < {$nowhouradd} OR endhour > {$nowhour}))
				)"; goto Gp4IH; FubO6: $latitude = $_COOKIE['kflatitude']; goto frfxY; s1YN0: $datafanskefu['kefunickname'] = $cservice['name']; goto Zrev8; iMVgQ: NhtKX: goto q8hTJ; IsTBB: if (!$cservice['autoreply']) { goto Kow9k; } goto cvDUT; B3l1x: zuMSi: goto fbXoZ; UWohe: gsFcH: goto B60qy; F1cQQ: $datafanskefu['kefuopenid'] = $cservice['content']; goto Fo4eC; tp0V5: $fangkearr['laiyuan'] = $_SERVER['HTTP_REFERER']; goto PV4KZ; TIXrP: CIaNL: goto uhURu; PSNuA: if (!($zhouji == '6')) { goto gsFcH; } goto aB8HA; MmdIJ: $zhouji = date('w'); goto GNzN4; FAaH0: FihFC: goto BIAyE; mYwkz: setcookie('kflongitude', $longitude, time() + 3600 * 24 * 7); goto ZdvlN; bIC0z: $condition .= ' OR (iszx = 1 AND isrealzx = 1))'; goto hNBDM; pmfbM: $datafanskefuup['kefunotread'] = 0; goto shG19; J8amD: $condition .= ' AND ((day7 = 1 AND isxingqi = 1) OR isxingqi = 0))'; goto iYdC7; OfskB: $condition .= ' AND ((day1 = 1 AND isxingqi = 1) OR isxingqi = 0))'; goto FAaH0; M44Xl: JtH7f: goto a9n2Q; B60qy: if (!($zhouji == '0')) { goto nA3lK; } goto J8amD; mcwsp: $nowhouradd = $nowhour + 1; goto uol_S; a9n2Q: if (empty($toopenid)) { goto E4GE3; } goto RcjRP; AHSWp: LuD1Z: goto F3qYx; Nu2J4: $auto = explode('|', $cservice['fansauto']); goto a6kfH; gDpPD: if (empty($hasfanskefu)) { goto cUDCk; } goto ZMUDJ; a6kfH: $hasfanskefu = pdo_fetch('SELECT * FROM ' . tablename(BEST_FANSKEFU) . " WHERE weid = {$_W['uniacid']} AND fansopenid = '{$openid}' AND kefuopenid = '{$toopenid}'"); goto gDpPD; yyUdT: E4GE3: goto C0Z8i; hWSKn: $title = ''; goto M44Xl; lwYtA: if (!empty($toopenid)) { goto JtH7f; } goto p7Y3I; BIAyE: if (!($zhouji == '2')) { goto LuD1Z; } goto SLECI; ibCWZ: $orderby = ' ORDER BY displayorder ASC'; goto lXarb; UEag9: preg_match_all($regex, $cservice['autoreply'], $array2); goto So2Ao; Mex1E: $mapkey = $this->getmoduleconfig('mapkey'); goto hraz2; PV4KZ: $fangkearr['gzhname'] = $_W['account']['name']; goto dFKUq; r8Hnj: $ipres = file_get_contents($ipurl); goto Ee3Zv; hL0Cj: $condition .= ' AND ((day5 = 1 AND isxingqi = 1) OR isxingqi = 0))'; goto vRDFN; q4yGx: pdo_insert(BEST_FANSKEFU, $datafanskefu); goto SsVsr; UdUSY: qaUOV: goto ibyJp; mcB3C: cUDCk: goto bQsgE; yNAEM: kyoKS: goto MmdIJ; gbt16: $nowhouradd = $nowhour + 1; goto NPZ0I; w0H0f: iHlmL: goto hWSKn; bqXTd: $cservicegroup = pdo_fetch('SELECT * FROM ' . tablename(BEST_CSERVICEGROUP) . " WHERE weid = {$_W['uniacid']} AND id = {$groupid}"); goto pSWC8; AAuxl: UbIek: goto Sbh3Y; HraMZ: $ipurl = 'https://apis.map.qq.com/ws/location/v1/ip?ip=' . $_W['clientip'] . '&key=' . $mapkey; goto Ocp_N; rchsg: setcookie('kflatitude', $latitude, time() + 3600 * 24 * 7); goto mYwkz; GI5RH: $title = '' . $cservice['name'] . ''; goto yyUdT; QX2aC: $fangkearr = array("lang" => $this->get_lang(), "browse" => $this->browse_info(), "os" => $this->get_os(), "ip" => $_W['clientip'], "laiyuan" => $_SERVER['HTTP_REFERER'], "latitude" => $ipres['result']['location']['lat'], "longitude" => $ipres['result']['location']['lng'], "nation" => $ipres['result']['ad_info']['nation'], "province" => $ipres['result']['ad_info']['province'], "city" => $ipres['result']['ad_info']['city'], "district" => $ipres['result']['ad_info']['district'], "gzhname" => $_W['account']['name']); goto UdUSY; A2gj9: $latitude = $ipres['result']['location']['lat'] . random(4, 1); goto IjweE; q8hTJ: if (!($zhouji == '5')) { goto pzeYX; } goto hL0Cj; gAdQO: if (empty($_COOKIE['kflatitude'])) { goto UbIek; } goto FubO6; u4QQU: foreach ($cservicelist as $k => $v) { goto o13Qe; eoSre: if (empty($kefuandgroup)) { goto JOqUm; } goto jEgxq; jEgxq: unset($cservicelist[$k]); goto DbFz8; PRLmU: KNTJY: goto irfbr; o13Qe: $kefuandgroup = pdo_fetch('SELECT id FROM ' . tablename(BEST_KEFUANDGROUP) . " WHERE kefuid = {$v['id']}"); goto eoSre; DbFz8: JOqUm: goto PRLmU; irfbr: } goto u0lEG; cvDUT: $regex = '@(?i)\\b((?:[a-z][\\w-]+:(?:/{1,3}|[a-z0-9%])|www\\d{0,3}[.]|[a-z0-9.\\-]+[.][a-z]{2,4}/)(?:[^\\s()<>]+|\\(([^\\s()<>]+|(\\([^\\s()<>]+\\)))*\\))+(?:\\(([^\\s()<>]+|(\\([^\\s()<>]+\\)))*\\)|[^\\s`!()\\[\\]{};:\'".,<>?]))@'; goto UEag9; A6DBr: $datafanskefu['weid'] = $_W['uniacid']; goto ep2iE; zA3Kk: $kefuandgroup = pdo_fetchall('SELECT kefuid FROM ' . tablename(BEST_KEFUANDGROUP) . " WHERE weid = {$_W['uniacid']} AND groupid = {$cservicegroup['id']}"); goto y9a6R; K1ylF: global $_W, $_GPC; goto Mex1E; Ee3Zv: $ipres = json_decode($ipres, true); goto bfzZj; Jxo8r: $ipres = json_decode($ipres, true); goto QX2aC; F3qYx: if (!($zhouji == '3')) { goto uqMNR; } goto ckOP6; hNBDM: $suiji = $this->getmoduleconfig('suiji'); goto mesm9; SsVsr: $hasfanskefu = pdo_fetch('SELECT * FROM ' . tablename(BEST_FANSKEFU) . " WHERE weid = {$_W['uniacid']} AND fansopenid = '{$openid}' AND kefuopenid = '{$toopenid}'"); goto k4vT8; hW4Zk: goto ouzN3; goto mcB3C; ZdvlN: wZAgh: goto r0_vZ; PB0YJ: goto wZAgh; goto AAuxl; hraz2: $defaultavatar = $this->getmoduleconfig('defaultavatar'); goto gAdQO; frfxY: $longitude = $_COOKIE['kflongitude']; goto PB0YJ; NPZ0I: $condition = "weid = {$_W['uniacid']} AND id in (" . implode(',', $kefuids) . ") AND ((iszx = 0 AND (
					(lingjie = 0 AND endhour >= {$nowhouradd} AND starthour <= {$nowhour}) OR 
					(lingjie = 1 AND (starthour < {$nowhouradd} OR endhour > {$nowhour}))
				)"; goto yNAEM; qT_xG: foreach ($kefuandgroup as $k => $v) { $kefuids[] = $v['kefuid']; thNW3: } goto TIXrP; Zrev8: $datafanskefu['fangke'] = serialize($fangkearr); goto q4yGx; Lgl56: if (!($zhouji == '4')) { goto NhtKX; } goto gzzMu; KrVZj: uqMNR: goto Lgl56; QtWdq: if ($fangkearr['latitude'] == '' || $fangkearr['ip'] != $_W['clientip']) { goto IfMbv; } goto tp0V5; p7Y3I: $groupid = intval($_GPC['groupid']); goto bqXTd; HL0TJ: } public function updatenowjdnum() { goto Rp0cx; lJ66M: RqDSh: goto JxJrO; Rp0cx: global $_W, $_GPC; goto yHXqF; dxFLF: foreach ($cservicelist as $k => $v) { goto wkmTp; MV28Q: pdo_update(BEST_CSERVICE, $data, array("id" => $v['id'])); goto aKEdP; wkmTp: $nowjdnum = pdo_fetchcolumn('SELECT COUNT(*) FROM ' . tablename(BEST_FANSKEFU) . " WHERE weid = {$_W['uniacid']} AND nowjd > 0 AND kefuopenid = '{$v['content']}'"); goto NcwHc; NcwHc: if (empty($nowjdnum)) { goto W0W8D; } goto ubjeT; ubjeT: $data['nowjdnum'] = $nowjdnum; goto MV28Q; mcuq_: A_dwc: goto tCXnK; aKEdP: W0W8D: goto mcuq_; tCXnK: } goto lJ66M; yHXqF: $cservicelist = pdo_fetchall('SELECT id,content FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = {$_W['uniacid']} AND ctype = 1"); goto dxFLF; JxJrO: } public function doMobileXiaxian() { goto hxly9; YVLyF: $data['kfzx'] = 0; goto uJVzU; eutQk: $data['kefunotread'] = 0; goto EoUMr; uJVzU: $data['notread'] = 0; goto HnD_o; aX0gW: GksC7: goto dUasw; cV30a: $data['fszx'] = 0; goto eutQk; EoUMr: pdo_update(BEST_FANSKEFU, $data, array("id" => $fkid)); goto hA3At; gx4Gb: $fkid = intval($_GPC['fkid']); goto Pvg8M; QSPgq: if (!($type == 'kefu')) { goto GksC7; } goto YVLyF; hxly9: global $_W, $_GPC; goto gx4Gb; Pvg8M: $type = trim($_GPC['type']); goto wtkbA; wtkbA: if (!($type == 'fans')) { goto PVa5Z; } goto cV30a; HnD_o: pdo_update(BEST_FANSKEFU, $data, array("id" => $fkid)); goto aX0gW; hA3At: PVa5Z: goto QSPgq; dUasw: } public function doMobileShangxian() { goto ZY92o; yFXd4: pdo_update(BEST_FANSKEFU, $data, array("id" => $fkid)); goto KPten; Lco0A: if (!($type == 'fans')) { goto kCbGH; } goto BFBck; BFBck: $data['fszx'] = 1; goto yFXd4; eve6F: $fkid = intval($_GPC['fkid']); goto sk0Ka; EQ5hL: if (!($type == 'kefu')) { goto YpqDW; } goto wXTfx; wXTfx: $data['kfzx'] = 1; goto m9bZG; h0Fkc: YpqDW: goto O4Eo8; sk0Ka: $type = trim($_GPC['type']); goto Lco0A; m9bZG: pdo_update(BEST_FANSKEFU, $data, array("id" => $fkid)); goto h0Fkc; ZY92o: global $_W, $_GPC; goto eve6F; KPten: kCbGH: goto EQ5hL; O4Eo8: } public function doMobileGetnew() { goto rlRVS; Dxd8D: $fansopenids = array(); goto G0O3r; XBz79: $newfans = pdo_fetchall('SELECT * FROM ' . tablename(BEST_FANSKEFU) . " WHERE weid = {$_W['uniacid']} AND kefuopenid = '{$openid}' AND notread > 0 ORDER BY lasttime DESC"); goto oW69u; t2NG5: $resArr['fansopenids'] = $fansopenids; goto prjg7; G0O3r: if (empty($newfans)) { goto y3kxj; } goto qmLoo; nqyid: exit; goto GeIzp; dFwVW: y3kxj: goto jgkIz; prjg7: echo json_encode($resArr); goto nqyid; J2acT: JyS0W: goto dFwVW; rlRVS: global $_W, $_GPC; goto Oh61M; qmLoo: foreach ($newfans as $k => $v) { goto HOchU; H2E1x: $notread = ''; goto UUDI7; Mnt2k: czmtX: goto Ke2xu; Ke2xu: $notread = '<span class="notread">' . $v['notread'] . '</span>'; goto wimHe; M5VwF: $fansopenids[$k] = $v['fansopenid']; goto Cs8_a; UUDI7: goto UHhDF; goto Mnt2k; Cs8_a: Loewx: goto QT0px; wimHe: UHhDF: goto WtJ7e; HOchU: if ($v['notread'] > 0) { goto czmtX; } goto H2E1x; WtJ7e: $html .= '<a href="' . $this->createMobileUrl('kefucenter', array("toopenid" => $v['fansopenid'])) . '" style="color:#fff;">
						<li data-openid="' . $v['fansopenid'] . '" class="new" style="position:relative;">
							<img class="avatar" src="' . $v['fansavatar'] . '" width="30" height="30">
							<p class="name">' . $v['fansnickname'] . '</p>
							' . $notread . '
						</li></a>'; goto M5VwF; QT0px: } goto J2acT; Oh61M: $openid = $_SESSION['openid']; goto XBz79; oW69u: $html = ''; goto Dxd8D; jgkIz: $resArr['html'] = $html; goto t2NG5; GeIzp: } public function doMobileDonotread() { goto TvIIf; MUdMd: pdo_update(BEST_FANSKEFU, $data, array("id" => $fkid)); goto tgXvs; fSxbi: pdo_update(BEST_FANSKEFU, $data, array("id" => $fkid)); goto WDUVN; tgXvs: USyAj: goto R7Mwl; Nmv0E: $type = trim($_GPC['type']); goto WAATc; iHwZ2: $data['notread'] = 0; goto fSxbi; TvIIf: global $_W, $_GPC; goto bmcAR; MAJkG: $data['kefunotread'] = 0; goto MUdMd; R7Mwl: if (!($type == 'kefu')) { goto zeHhB; } goto iHwZ2; WDUVN: zeHhB: goto MAq4s; WAATc: if (!($type == 'fans')) { goto USyAj; } goto MAJkG; bmcAR: $fkid = intval($_GPC['fkid']); goto Nmv0E; MAq4s: } public function doMobileDonotread2() { goto sYPTq; sYPTq: global $_W, $_GPC; goto IT50i; tXdlc: pdo_update(BEST_XCXFANSKEFU, $data, array("id" => $fkid)); goto f9zgE; IT50i: $fkid = intval($_GPC['fkid']); goto LOekW; LOekW: $data['notread'] = 0; goto tXdlc; f9zgE: } public function doMobileAddbiaoqian() { goto u7tg8; E5dJL: exit; goto elDrT; v6egk: echo json_encode($resArr); goto NJQX5; J2kqP: $has = pdo_fetch('SELECT * FROM ' . tablename(BEST_BIAOQIAN) . " WHERE kefuopenid = '{$openid}' AND fensiopenid = '{$toopenid}' AND weid = {$_W['uniacid']}"); goto DgHRH; fB0RY: $data['name'] = $name; goto bCrax; w46Z0: VFWvw: goto Qgakk; NJQX5: exit; goto ZD5VG; Cxijo: $resArr['msg'] = ''; goto v6egk; xet3m: $data['weid'] = $_W['uniacid']; goto Ux0jc; apzXq: $toopenid = trim($_GPC['toopenid']); goto J2kqP; DCJFO: echo json_encode($resArr); goto c9l27; Ux0jc: $data['kefuopenid'] = $openid; goto WqAz3; u7tg8: global $_W, $_GPC; goto LIX9d; GhHYB: $resArr['msg'] = ''; goto mrqtv; K83Qq: $resArr['error'] = 1; goto GhHYB; RN6SI: $resArr['error'] = 1; goto CNvE0; LIX9d: $openid = $_SESSION['openid']; goto Dhn7p; Jenmq: dDtft: goto YFK4C; c9l27: exit; goto w46Z0; e8h0n: if (!empty($name)) { goto Ir672; } goto K83Qq; SOZ6O: $data['telphone'] = $telphone; goto j3w25; VnlOD: $telphone = trim($_GPC['telphone']); goto apzXq; Dhn7p: if (!empty($openid)) { goto VFWvw; } goto RN6SI; BFazh: $realname = trim($_GPC['realname']); goto VnlOD; DgHRH: if ($has) { goto cs9Lu; } goto xet3m; WqAz3: $data['fensiopenid'] = $toopenid; goto fB0RY; dlDtt: pdo_update(BEST_BIAOQIAN, array("name" => $name, "realname" => $realname, "telphone" => $telphone), array("kefuopenid" => $openid, "fensiopenid" => $toopenid, "weid" => $_W['uniacid'])); goto Jenmq; YFK4C: $resArr['error'] = 0; goto Cxijo; Qgakk: $name = trim($_GPC['name']); goto e8h0n; mrqtv: echo json_encode($resArr); goto E5dJL; Xi_JK: goto dDtft; goto yG2ZC; j3w25: pdo_insert(BEST_BIAOQIAN, $data); goto Xi_JK; yG2ZC: cs9Lu: goto dlDtt; CNvE0: $resArr['msg'] = ''; goto DCJFO; elDrT: Ir672: goto BFazh; bCrax: $data['realname'] = $realname; goto SOZ6O; ZD5VG: } public function sendtplmsg($senddata) { goto Nmr1W; lH0EZ: if (!($istplon == 1)) { goto VaXXd; } goto M0YXb; f2y2S: $account_api->sendTplNotice($senddata['openid'], $tpl_kefu, $postdata, $senddata['url'], '#980000'); goto M1TEf; Nmr1W: global $_GPC, $_W; goto rq0C6; qcM2E: RURp5: goto hlBSY; yVJA2: $account_api->sendCustomNotice($send); goto FefZ4; H7yGN: $texturl = '<a href=\'' . $senddata['url'] . '\'></a>'; goto eoA3d; Knihv: $account_api = WeAccount::create(); goto yVJA2; rq0C6: $istplon = $this->getmoduleconfig('istplon'); goto Fbb0A; Fbb0A: $tpl_kefu = $this->getmoduleconfig('tpl_kefu'); goto lH0EZ; M0YXb: if ($tpl_kefu != '' && $senddata['wherefrom'] != 1) { goto RURp5; } goto H7yGN; M1TEf: oeA0n: goto ZWbab; hlBSY: $postdata = array("keyword1" => array("value" => $senddata['keyword1'], "color" => "#ff510"), "keyword2" => array("value" => date('Y-m-d H:i:s', TIMESTAMP), "color" => "#ff510"), "remark" => array("value" => $senddata['first'], "color" => "#0000CD")); goto mAto1; mAto1: $account_api = WeAccount::create(); goto f2y2S; SclZX: $send['msgtype'] = 'text'; goto fD6qs; ZWbab: VaXXd: goto ns1t9; fD6qs: $send['text'] = array("content" => urlencode($senddata['first'])); goto Knihv; FefZ4: goto oeA0n; goto qcM2E; eoA3d: $send['touser'] = $senddata['openid']; goto SclZX; ns1t9: } public function doMobileAddchat() { goto Cpq0Z; shoeG: ahzno: goto qQvMc; WjA09: $datajqr['nickname'] = $cservice['name']; goto REEuf; Nz2gh: $dataup_fanskefu['nowjd'] = 1; goto g6KTN; cguNz: sIZP_: goto mdszJ; wt2Lz: echo json_encode($resArr); goto Zw8p1; imCU0: FBSRH: goto ZZJBi; iALbv: $datajqr['content'] = $zdhf['allcon']; goto Z8GxE; M3CIq: $tplurl = str_replace('cy163_customerservice_plugin_p', 'cy163_customerservice', $tplurl); goto fhmNG; pGPVM: echo json_encode($resArr); goto B60Np; QnCGp: $chatid = pdo_insertid(); goto gc9H5; TqHgn: pdo_insert(BEST_CHAT, $data); goto QnCGp; XiDoz: Gxof5: goto imCU0; Ohpef: lZvaw: goto ObxSz; BXRPt: $zhouji = date('w'); goto r8t_W; GN2b8: ekAfE: goto fMb0L; HReHD: if (!($guotime > $kefutplminute)) { goto jh7dA; } goto fO1r5; xMbQM: exit; goto tvT09; ZZsJM: $resArr['error'] = 1; goto kSJcm; DzR6v: JNdOV: goto Qv7Q3; iSK_L: $resArr['jqrtime'] = date('Y-m-d H:i:s', $jqrtime); goto RJwbW; mPKkm: $dataup_fanskefu['lastcon'] = $lastcon; goto vSuof; VNXOt: N1vju: goto RnRXX; DoMyM: $resArr['error'] = 1; goto W127V; FBoYi: $resArr['error'] = 1; goto w9upg; Erf_I: echo json_encode($resArr); goto I2vbD; y6upI: $tplcon = $this->guolv($tplcon); goto TqHgn; GKVCG: APfwG: goto QXpo0; KnZUI: goto Xd0P5; goto tH_dp; oJib7: $resArr['jqravatar'] = tomedia($cservice['thumb']); goto r19Iv; JWPrA: $data['avatar'] = $fanskefu['fansavatar']; goto o8bGT; qJ3kN: if (!($cservice['day4'] == 0)) { goto ekAfE; } goto FFN4Z; FBJsB: $otherfanskefus = pdo_fetchall('SELECT id,kefuopenid FROM ' . tablename(BEST_FANSKEFU) . " WHERE weid = {$_W['uniacid']} AND nowjd > 0 AND fansopenid = '{$openid}' AND kefuopenid != '{$cservice['content']}'"); goto SVziu; resap: echo json_encode($resArr); goto RQm6R; EQ3UZ: if ($zhouji == '5') { goto FHdC5; } goto o7Z4L; XAT6l: if ($cservice['iszx'] == 1) { goto SfGke; } goto yLr67; FcueQ: exit; goto bOv_Z; dXgSu: $datajqr['type'] = $zdhf['hftype'] == 0 || $zdhf['hftype'] == 3 ? 2 : 4; goto IzJRO; QspIx: d4Mec: goto Dqiam; qQvMc: bDm_g: goto nVtIj; UOW9k: S0dio: goto cguNz; Rjb_7: HDP0z: goto cJcUk; mdszJ: goto lZvaw; goto GOGE_; gNfn6: $resArr['msg'] = $notonlinemsg; goto pGPVM; b4HOK: pdo_update(BEST_FANSKEFU, $dataup_fanskefu, array("id" => $fanskefu['id'])); goto XNCfS; n6ucW: $dataup_fanskefu['lasttime'] = TIMESTAMP; goto b4HOK; WxCm5: if ($zhouji == '3') { goto d4Mec; } goto WQTVT; bOv_Z: J1q01: goto wNSKa; NrYxy: $regex = '@(?i)\\b((?:[a-z][\\w-]+:(?:/{1,3}|[a-z0-9%])|www\\d{0,3}[.]|[a-z0-9.\\-]+[.][a-z]{2,4}/)(?:[^\\s()<>]+|\\(([^\\s()<>]+|(\\([^\\s()<>]+\\)))*\\))+(?:\\(([^\\s()<>]+|(\\([^\\s()<>]+\\)))*\\)|[^\\s`!()\\[\\]{};:\'".,<>?]))@'; goto iVGan; iU3tu: $resArr['content'] = $this->doReplacecon($data['content'], $data['type']); goto vQJUO; Rj_el: $nowhour = intval(date('H', TIMESTAMP)); goto y0x3g; oZp61: $chatcontent = trim($_GPC['content']); goto QzN28; WKIcu: $nowhour = intval(date('H', TIMESTAMP)); goto RZjWE; Hxsii: $data['openid'] = $fanskefu['fansopenid']; goto cGxJl; r19Iv: $datajqr['weid'] = $_W['uniacid']; goto vJ4_X; aaqiV: echo json_encode($resArr); goto xMbQM; G1rvW: exit; goto DzR6v; VNWd6: if (!($zdhf['hftype'] == 0)) { goto ZwvZL; } goto RMEW4; YFeIa: echo json_encode($resArr); goto j4ML_; J99Mw: jh7dA: goto ls_kS; RJwbW: $resArr['hftype'] = $zdhf['hftype']; goto VNWd6; EzCXz: echo json_encode($resArr); goto ShbXq; RvdXT: if (!($cservice['day7'] == 0)) { goto pSEsN; } goto rlKdo; LBHjW: tR6p9: goto iaJS5; qiUXK: $resArr['error'] = 1; goto QEs9x; dB0kF: hoWrH: goto LZMc_; GaqcS: OlTUr: goto Ohpef; y0x3g: if (!($nowhour < $cservice['starthour'] || $nowhour + 1 > $cservice['endhour'])) { goto J1q01; } goto GFcz4; VzeIr: $resArr['jqrcontent'] = $datajqr['content'] = tomedia($zdhf['imgcon']); goto Rjb_7; REEuf: $datajqr['avatar'] = tomedia($cservice['thumb']); goto dXgSu; QzN28: $lastcon = preg_replace('/\\xEE[\\x80-\\xBF][\\x80-\\xBF]|\\xEF[\\x81-\\x83][\\x80-\\xBF]/', '[]', $chatcontent); goto JIIGn; R5IBb: $jqrtime = $data['time'] + 1; goto iSK_L; WJLIa: YgI9w: goto Iysjy; g6KTN: $dataup_fanskefu['jdtime'] = TIMESTAMP; goto FBJsB; FCe5t: $dataup_fanskefu['kefudel'] = 0; goto mPKkm; iquYB: $resArr['msg'] = $notonlinemsg; goto wt2Lz; W127V: $resArr['msg'] = ''; goto lQv3c; S2YOt: $resArr['error'] = 1; goto iquYB; pfJT1: $resArr['msg'] = $notonlinemsg; goto IhJcp; oRz9u: Nvxzl: goto YKG8m; ZZJBi: goto Ld_qp; goto sRIND; RMEW4: $datajqr['content'] = $zdhf['content']; goto NrYxy; MIgGW: if (!($cservice['day1'] == 0)) { goto OlTUr; } goto ZZsJM; iep1I: if (!($cservice['isrealzx'] == 0)) { goto ahzno; } goto vjUji; GOGE_: jj8Ju: goto MIgGW; HRqU2: if ($type == 3 || $type == 4) { goto igx06; } goto egvFl; SVRAG: $resArr['error'] = 1; goto SsaL7; dOM8t: SfGke: goto iep1I; rPUe0: $datajqr['toopenid'] = $data['openid']; goto oior6; q_9i8: FHdC5: goto E_1VD; vSuof: $dataup_fanskefu['msgtype'] = $type; goto n6ucW; ACAZM: $data['type'] = $type; goto HRqU2; WQTVT: if ($zhouji == '4') { goto r011z; } goto EQ3UZ; vjUji: $notonlinemsg = !empty($cservice['notonline']) ? $cservice['notonline'] : ''; goto S2YOt; WgvOw: $resArr['msg'] = ''; goto iU3tu; IhJcp: echo json_encode($resArr); goto Zsqui; dlqWw: $resArr['jqr'] = 1; goto R5IBb; XE1NN: $dataup_fanskefu['notread'] = $fanskefu['notread'] + 1; goto l6GSx; ls_kS: if (!($fanskefu['nowjd'] == 0)) { goto zlJ9c; } goto Nz2gh; lqjIB: ERANe: goto jXAlV; iVGan: preg_match_all($regex, $zdhf['content'], $array2); goto mBLEG; EyM9F: $resArr['msg'] = $notonlinemsg; goto YFeIa; Iysjy: $cservice = pdo_fetch('SELECT * FROM ' . tablename(BEST_CSERVICE) . " WHERE weid = {$_W['uniacid']} AND ctype = 1 AND content = '{$_GPC['toopenid']}'"); goto XAT6l; Cpq0Z: global $_W, $_GPC; goto oZp61; Zw8p1: exit; goto shoeG; QXpo0: if (!($cservice['day6'] == 0)) { goto ERANe; } goto SVRAG; c6460: echo json_encode($resArr); goto FcueQ; B60Np: exit; goto VNXOt; lQv3c: echo json_encode($resArr); goto aSMWU; w9upg: $resArr['msg'] = $notonlinemsg; goto aaqiV; wNSKa: goto gmKAq; goto Mrqcu; XzEEH: Jl1Lx: goto oJib7; RZjWE: if (!($nowhour + 1 > $cservice['endhour'] && $nowhour < $cservice['starthour'])) { goto JNdOV; } goto yLHwd; rlKdo: $resArr['error'] = 1; goto djGij; egvFl: $tplcon = $data['content']; goto KnZUI; sRIND: r011z: goto qJ3kN; yLr67: if ($cservice['lingjie'] == 1) { goto FbD8a; } goto Rj_el; yLHwd: $notonlinemsg = !empty($cservice['notonline']) ? $cservice['notonline'] : ''; goto wDjW2; Qv7Q3: gmKAq: goto jZLwe; V49Ip: $data['fkid'] = intval($_GPC['fkid']); goto XzVS6; IgwUw: $data['weid'] = $_W['uniacid']; goto k1_PL; VNq8s: $resArr['error'] = 1; goto UHq_o; Cu0cg: zlJ9c: goto XE1NN; JwyMI: $datajqr['openid'] = trim($_GPC['toopenid']); goto rPUe0; cJcUk: if (!($zdhf['hftype'] == 3)) { goto Jl1Lx; } goto iALbv; ObxSz: i_bHF: goto V49Ip; oior6: $datajqr['time'] = $jqrtime; goto WjA09; ducH_: $tplcon = $data['nickname'] . ''; goto NVKeZ; djGij: $resArr['msg'] = $notonlinemsg; goto EzCXz; TllnB: goto sIZP_; goto NUE6F; RnRXX: srsNu: goto TllnB; SsaL7: $resArr['msg'] = $notonlinemsg; goto UOgvP; o7Z4L: if ($zhouji == '6') { goto APfwG; } goto mN_sm; Wq0yz: ZwvZL: goto KHJyy; VDP1v: $dataup_fanskefu['fansdel'] = 0; goto FCe5t; bnXbq: $guotime = TIMESTAMP - $fanskefu['lasttime']; goto HReHD; NVKeZ: Xd0P5: goto y6upI; mN_sm: if ($zhouji == '0') { goto iogLp; } goto FBoYi; DCoQb: goto srsNu; goto QspIx; ShbXq: exit; goto umSyW; WM_LQ: $data['content'] = $chatcontent; goto IgwUw; KFRH7: $data['time'] = TIMESTAMP; goto WM_LQ; jeVgw: echo json_encode($resArr); goto G1rvW; egofg: $dataup_fanskefu['wherefrom'] = 0; goto VDP1v; I2vbD: exit; goto XiDoz; nVtIj: if (!($cservice['isxingqi'] == 1)) { goto i_bHF; } goto AAasT; IzJRO: $datajqr['isjqr'] = 1; goto O69r2; O69r2: pdo_insert(BEST_CHAT, $datajqr); goto S0iOM; GFcz4: $notonlinemsg = !empty($cservice['notonline']) ? $cservice['notonline'] : ''; goto qiUXK; tvT09: goto hoWrH; goto GxfUD; jZLwe: goto bDm_g; goto dOM8t; JIIGn: if (!empty($chatcontent)) { goto YgI9w; } goto DoMyM; lhGPs: if (empty($zdhf)) { goto DlKwA; } goto dlqWw; yeS88: foreach ($array2[0] as $kk => $vv) { goto zGJB2; dLnKT: Gxvxu: goto CNI1Q; dKhQS: $zdhf['content'] = str_replace($vv, '<a href=\'' . $vvurl . '\'>' . $vv . '</a>', $zdhf['content']); goto eX430; zGJB2: if (empty($vv)) { goto oCTOb; } goto WQf1I; eX430: oCTOb: goto dLnKT; WQf1I: $vvurl = strstr($vv, 'http') ? $vv : 'http://' . $vv; goto dKhQS; CNI1Q: } goto ZOi9m; tH_dp: igx06: goto ducH_; l6GSx: $dataup_fanskefu['guanlinum'] = $fanskefu['guanlinum'] + 1; goto egofg; RQm6R: exit; goto Wep8j; jXAlV: xp2Ub: goto H6NTv; o8bGT: $data['toopenid'] = trim($_GPC['toopenid']); goto KFRH7; ZOi9m: ab4p0: goto LBHjW; UHq_o: $resArr['msg'] = $notonlinemsg; goto Erf_I; S0iOM: DlKwA: goto I3GId; vJ4_X: $datajqr['fkid'] = intval($_GPC['fkid']); goto JwyMI; XzVS6: $fanskefu = pdo_fetch('SELECT * FROM ' . tablename(BEST_FANSKEFU) . " WHERE weid = {$_W['uniacid']} AND id = {$data['fkid']}"); goto Hxsii; gc9H5: $zdhf = pdo_fetch('select * from ' . tablename(BEST_ZIDONGHUIFU) . " where weid = {$_W['uniacid']} AND ((title = '{$chatcontent}' AND type = 1) OR (INSTR('{$chatcontent}',title) AND type = 2)) ORDER BY paixu DESC"); goto lhGPs; fhmNG: $senddata = array("openid" => $data['toopenid'], "url" => $tplurl, "first" => $tplcon, "keyword1" => $data['nickname']); goto sCpZ2; Mf8c8: if ($zhouji == '2') { goto kD7gl; } goto WxCm5; XNCfS: $resArr['error'] = 0; goto WgvOw; Mrqcu: FbD8a: goto WKIcu; GxfUD: iogLp: goto RvdXT; Dqiam: if (!($cservice['day3'] == 0)) { goto N1vju; } goto lvMaQ; fO1r5: $tplurl = $this->gettpldomain() . 'app/' . str_replace('./', '', $this->createMobileUrl('servicechat', array("ssopenid" => $data['openid'], "toopenid" => $data['openid']))); goto M3CIq; SVziu: foreach ($otherfanskefus as $k => $v) { goto bKU3j; cMWnH: B_yMX: goto SbYXJ; bKU3j: $dataotherfk['nowjd'] = 0; goto QyS0k; QyS0k: $dataotherfk['jdtime'] = 0; goto X346T; X346T: pdo_update(BEST_FANSKEFU, $dataotherfk, array("id" => $v['id'])); goto cMWnH; SbYXJ: } goto oRz9u; vQJUO: $resArr['datetime'] = date('Y-m-d H:i:s', $data['time']); goto JhhUe; Zsqui: exit; goto GN2b8; YKG8m: $this->updatenowjdnum(); goto Cu0cg; rj9IT: $resArr['error'] = 1; goto EyM9F; iaJS5: $resArr['jqrcontent'] = $zdhf['content']; goto Wq0yz; X4v3Q: if (!($cservice['day2'] == 0)) { goto S0dio; } goto rj9IT; umSyW: pSEsN: goto dB0kF; kSJcm: $resArr['msg'] = $notonlinemsg; goto tUQ9k; mBLEG: if (empty($array2[0])) { goto tR6p9; } goto yeS88; H6NTv: goto FBSRH; goto q_9i8; Z8GxE: $resArr['jqrcontent'] = htmlspecialchars_decode($zdhf['allcon']); goto XzEEH; QEs9x: $resArr['msg'] = $notonlinemsg; goto c6460; ma0gm: exit; goto GaqcS; UOgvP: echo json_encode($resArr); goto SbZx5; j4ML_: exit; goto UOW9k; AAasT: $notonlinemsg = !empty($cservice['notonline']) ? $cservice['notonline'] : ''; goto BXRPt; lvMaQ: $resArr['error'] = 1; goto gNfn6; DPd5Q: $resArr['msg'] = $notonlinemsg; goto jeVgw; sCpZ2: $this->sendtplmsg($senddata); goto J99Mw; LZMc_: goto xp2Ub; goto GKVCG; fMb0L: Ld_qp: goto DCoQb; NUE6F: kD7gl: goto X4v3Q; aSMWU: exit; goto WJLIa; r8t_W: if ($zhouji == '1') { goto jj8Ju; } goto Mf8c8; cGxJl: $data['nickname'] = $fanskefu['fansnickname']; goto JWPrA; SbZx5: exit; goto lqjIB; FFN4Z: $resArr['error'] = 1; goto pfJT1; E_1VD: if (!($cservice['day5'] == 0)) { goto Gxof5; } goto VNq8s; I3GId: pdo_query('update ' . tablename(BEST_FANSKEFU) . ' set notread=notread+1,guanlinum=guanlinum+1,wherefrom=0 where id=:id', array(":id" => $data['fkid'])); goto hSo_o; tUQ9k: echo json_encode($resArr); goto ma0gm; hSo_o: $kefutplminute = $this->getmoduleconfig('kefutplminute'); goto bnXbq; k1_PL: $type = intval($_GPC['type']); goto ACAZM; KHJyy: if (!($zdhf['hftype'] == 2)) { goto HDP0z; } goto VzeIr; wDjW2: $resArr['error'] = 1; goto DPd5Q; JhhUe: $resArr['chatid'] = $chatid; goto resap; Wep8j: } public function gettpldomain() { goto A8y_T; Rbe15: $tpldomain = $this->getmoduleconfig('tpldomain'); goto rWrz7; rWrz7: return $tpldomain != '' ? $tpldomain : $_W['siteroot']; goto zDoKz; A8y_T: global $_W, $_GPC; goto Rbe15; zDoKz: } public function doMobileAddchatxcx() { goto XevQW; LDNBr: ANHOs: goto SfdGN; wYjDP: $msgtype = 'text'; goto jfgNq; m3qun: $resArr['error'] = 1; goto JQp9V; JjXyU: $data['gh_id'] = $fanskefu['gh_id']; goto SXTsG; XevQW: global $_W, $_GPC; goto JCXvk; pAqyj: a09Bh: goto oXeFu; O6MCu: $chatcontent = tomedia($chatcontent); goto SjNWB; RzVDV: if ($type == 2) { goto JV4Ep; } goto C1ThA; JnMyB: if (!($type == 2)) { goto ZUCxA; } goto wYjDP; EXDgB: echo json_encode($resArr); goto hEKc4; X9Rru: $data['weid'] = $_W['uniacid']; goto KSg_H; jfgNq: $dataup['lastcon'] = preg_replace('/\\xEE[\\x80-\\xBF][\\x80-\\xBF]|\\xEF[\\x81-\\x83][\\x80-\\xBF]/', '[]', $chatcontent); goto d9xD3; wqwZU: $dataup['msgtype'] = $msgtype; goto JYlVx; Q1328: $data['openid'] = $fanskefu['kefuopenid']; goto z2Inx; ASl97: if (!($addres['errcode'] == '40001')) { goto feXAf; } goto Ar5kG; sEXEI: if (!($type == 3)) { goto svNBJ; } goto Tdl9a; xqUJQ: XZebZ: goto C9ufw; EQx_7: if (!empty($chatcontent)) { goto vjMaG; } goto m3qun; hEKc4: exit; goto pAqyj; G4mtX: vjMaG: goto ZExoj; NlJM7: $addres = $this->addxcxchat2($fanskefu['fansopenid'], $chatcontent, $msgtype, $fanskefu['gh_id']); goto ASl97; StCbB: echo json_encode($resArr); goto hblbC; d9xD3: ZUCxA: goto sEXEI; MkyD1: feXAf: goto Iyrh_; Tdl9a: $msgtype = 'image'; goto O6MCu; Ar5kG: $addres = $this->addxcxchat2($fanskefu['fansopenid'], $chatcontent, $msgtype, $fanskefu['gh_id'], 1); goto MkyD1; vym3P: JV4Ep: goto nGGZG; SNhTp: $resArr['msg'] = $this->getwxerrormsg($addres); goto EXDgB; HXXp7: $chatcontent = trim($_GPC['content']); goto EQx_7; S87zy: $data['msgtype'] = $msgtype; goto ksHtw; KSg_H: $data['fkid'] = $fkid; goto S87zy; a_5Tl: exit; goto LHvXy; z2Inx: $data['toopenid'] = $fanskefu['fansopenid']; goto JjXyU; nGGZG: $resArr['content'] = '<div class="concon">' . $chatcontent . '</div>'; goto xqUJQ; JCXvk: $fkid = intval($_GPC['fkid']); goto GUnkH; ZExoj: $fanskefu = pdo_fetch('SELECT * FROM ' . tablename(BEST_XCXFANSKEFU) . " WHERE id = {$fkid}"); goto JnMyB; x7LFo: $data['content'] = $chatcontent; goto X9Rru; Zz0n_: $dataup['lasttime'] = $data['time']; goto wqwZU; SXTsG: $data['time'] = $addres['time']; goto x7LFo; JQp9V: $resArr['msg'] = ''; goto StCbB; ksHtw: pdo_insert(BEST_XCXCHAT, $data); goto Zz0n_; Iyrh_: if ($addres['errcode'] != '0') { goto ANHOs; } goto Q1328; rVWal: $resArr['msg'] = ''; goto Z1ACX; SjNWB: $dataup['lastcon'] = '[]'; goto WA2c6; C1ThA: $resArr['content'] = '<div class="concon"><img src="' . $chatcontent . '" class="sssbbb" /></div>'; goto avjXh; GUnkH: $type = intval($_GPC['type']); goto HXXp7; SfdGN: $resArr['error'] = 1; goto SNhTp; WA2c6: svNBJ: goto NlJM7; hblbC: exit; goto G4mtX; avjXh: goto XZebZ; goto vym3P; C9ufw: $resArr['error'] = 0; goto rVWal; SqtOE: echo json_encode($resArr); goto a_5Tl; JYlVx: pdo_update(BEST_XCXFANSKEFU, $dataup, array("id" => $fkid)); goto RzVDV; Z1ACX: $resArr['datetime'] = date('Y-m-d H:i:s', $data['time']); goto SqtOE; LHvXy: goto a09Bh; goto LDNBr; oXeFu: } public function addxcxchat2($touser, $content, $msgtype, $gh_id, $isnewtoken = 0) { goto Y8qa4; kEulT: exit; goto nzrx3; X12EJ: echo json_encode($resArr); goto vY2Jm; UKmIh: file_put_contents('../addons/cy163_customerservice/' . $fileName, $source); goto P0WAL; Be05l: $kefutokehures = $this->curl_post($url, $json); goto w2mZU; PWN2s: $imgres = $this->curl_post2($imgurl, '../addons/cy163_customerservice/' . $fileName); goto bBNmZ; SKYMa: DiXcq: goto z592U; GJnkv: if (!($msgtype == 'image')) { goto U6oE2; } goto LRqfZ; KTzMu: U6oE2: goto z979G; pn74L: $data = array("touser" => $touser, "msgtype" => "link", "link" => array("title" => $content['title'], "description" => $content['description'], "url" => $content['url'], "thumb_url" => $content['thumb_url'])); goto SKYMa; g3Mek: $access_token = $this->get_xcx_accessToken($xcx['appid'], $xcx['secret']); goto OZf7j; abfMF: return $kefutokehures; goto zPUyi; sPOkI: $data = array("touser" => $touser, "msgtype" => "text", "text" => array("content" => $content)); goto Z42BA; XZvdx: echo json_encode($resArr); goto kEulT; MlqLV: $dataup['guoqitime'] = $nowtime + 3600; goto eayLE; qJ_ql: $resArr['msg'] = 'AccessToken'; goto XZvdx; LNxTZ: $data = array("touser" => $touser, "msgtype" => "image", "image" => array("media_id" => $imgres['media_id'])); goto KTzMu; v40Mn: zC81b: goto ovmia; fwdv4: $resArr['error'] = 1; goto oGUq6; HEOYe: goto A6KQr; goto GiZZZ; mjoLD: $dataup['guoqitime'] = $nowtime + 3600; goto lhAqq; m1ThT: $xcx = pdo_fetch('SELECT * FROM ' . tablename(BEST_XCX) . " WHERE uniacid = {$_W['uniacid']} AND gh_id = '{$gh_id}'"); goto VswrL; w2mZU: $kefutokehures = json_decode($kefutokehures, true); goto uAL_h; llIfY: $dataup['access_token'] = $access_token; goto MlqLV; vY2Jm: exit; goto v40Mn; NldgV: $json = json_encode($data, JSON_UNESCAPED_UNICODE); goto Be05l; nzrx3: odYLf: goto llIfY; PbcEa: q_ASt: goto g3Mek; LRqfZ: $fileName = time() . '.jpg'; goto hks3s; hks3s: $source = file_get_contents($content); goto UKmIh; P0WAL: $imgurl = 'http://api.weixin.qq.com/cgi-bin/media/upload?access_token=' . $access_token . '&type=image'; goto PWN2s; k_VQB: $access_token = $xcx['access_token']; goto HEOYe; z979G: if (!($msgtype == 'link')) { goto DiXcq; } goto pn74L; z592U: $url = 'https://api.weixin.qq.com/cgi-bin/message/custom/send?access_token=' . $access_token; goto NldgV; lhAqq: pdo_update(BEST_XCX, $dataup, array("id" => $xcx['id'])); goto VzRuN; GiZZZ: aNwra: goto aG52n; uAL_h: $kefutokehures['time'] = $nowtime; goto abfMF; bBNmZ: unlink('../addons/cy163_customerservice/' . $fileName); goto LNxTZ; rB3Di: if (!($access_token == 'error')) { goto odYLf; } goto XU9nN; ZhAhL: if (!($msgtype == 'text')) { goto zcbga; } goto sPOkI; oGUq6: $resArr['msg'] = 'AccessToken'; goto X12EJ; LStXM: $nowtime = TIMESTAMP; goto m1ThT; Z42BA: zcbga: goto GJnkv; up7J3: if ($xcx['guoqitime'] < TIMESTAMP) { goto aNwra; } goto k_VQB; OVVGn: A6KQr: goto e2VQf; VswrL: if ($isnewtoken == 1) { goto q_ASt; } goto up7J3; Y8qa4: global $_GPC, $_W; goto LStXM; XU9nN: $resArr['error'] = 1; goto qJ_ql; eayLE: pdo_update(BEST_XCX, $dataup, array("id" => $xcx['id'])); goto OVVGn; e2VQf: goto bdNwD; goto PbcEa; VzRuN: bdNwD: goto ZhAhL; aG52n: $access_token = $this->get_xcx_accessToken($xcx['appid'], $xcx['secret']); goto rB3Di; OZf7j: if (!($access_token == 'error')) { goto zC81b; } goto fwdv4; ovmia: $dataup['access_token'] = $access_token; goto mjoLD; zPUyi: } public function get_xcx_accessToken($appid, $appsecret) { goto D_uZR; OQTNJ: return 'error'; goto GdgW1; GdgW1: goto Pm7mv; goto DIq2T; PdlU3: if ($res) { goto m19jp; } goto OQTNJ; DIq2T: m19jp: goto bnjuE; bnjuE: return $res['access_token']; goto F2f6w; F2f6w: Pm7mv: goto mEwZr; UOdzt: $result = $this->curl_get_https($url); goto AwM3F; AwM3F: $res = json_decode($result, true); goto PdlU3; D_uZR: $url = 'https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential&appid=' . $appid . '&secret=' . $appsecret; goto UOdzt; mEwZr: } public function curl_get_https($url) { goto tQj5j; kq10g: curl_setopt($curl, CURLOPT_URL, $url); goto yH6Fn; orTb6: curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, true); goto K1lNK; K1lNK: $tmpInfo = curl_exec($curl); goto E2n_e; Klw2a: curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false); goto orTb6; yH6Fn: curl_setopt($curl, CURLOPT_HEADER, 0); goto I9AyY; tQj5j: $curl = curl_init(); goto kq10g; I9AyY: curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1); goto Klw2a; V7i1v: return $tmpInfo; goto TU_cp; E2n_e: curl_close($curl); goto V7i1v; TU_cp: } public function getwxerrormsg($addres) { goto MB_aa; CsdKk: Rlacv: goto BCJij; b00vm: $errmsg = 'API '; goto J_TIW; PDCQe: if ($addres['errcode'] == '40001') { goto hqq16; } goto ATrMQ; Hrjb7: zKGuI: goto K9RUN; YoqQd: $errmsg = ' access_token  AppSecret  access_token  AppSecret '; goto EPLlD; Kuh8m: goto u0ecF; goto SK3w_; BCJij: $errmsg = ''; goto Kuh8m; SK3w_: hqq16: goto YoqQd; K9RUN: $errmsg = ''; goto eYHKC; zdUlU: $errmsg = $addres['errmsg']; goto R6axz; EPLlD: goto u0ecF; goto fw9uM; Yz4pv: u0ecF: goto jA_C5; kuFxe: $errmsg = ' OpenID OpenID  OpenID'; goto AWgER; dk34A: if ($addres['errcode'] == '40003') { goto bDFb7; } goto cjbZ6; EikiM: UjbGd: goto b00vm; MB_aa: if ($addres['errcode'] == '45047') { goto b6xYN; } goto lXwGi; e1_Ug: if ($addres['errcode'] == '45015') { goto zKGuI; } goto dk34A; ATrMQ: if ($addres['errcode'] == '-1') { goto eh2O9; } goto zdUlU; PFC1Z: $errmsg = ''; goto wEMBW; fw9uM: eh2O9: goto o3L_D; AWgER: goto u0ecF; goto CsdKk; FBLCd: b6xYN: goto PFC1Z; wEMBW: goto u0ecF; goto EikiM; eYHKC: goto u0ecF; goto PHfXv; o3L_D: $errmsg = ''; goto Yz4pv; R6axz: goto u0ecF; goto FBLCd; lXwGi: if ($addres['errcode'] == '48001') { goto UjbGd; } goto e1_Ug; cjbZ6: if ($addres['errcode'] == '40002') { goto Rlacv; } goto PDCQe; PHfXv: bDFb7: goto kuFxe; J_TIW: goto u0ecF; goto Hrjb7; jA_C5: return $errmsg; goto BrDGE; BrDGE: } public function curl_post($url, $data = array()) { goto upQ7f; mhBu2: if (curl_errno($ch)) { goto c83n9; } goto Jv25Y; QZoWj: return $rs; goto oECYi; upQ7f: $ch = curl_init(); goto l8gn1; K0Kkc: $rs = curl_exec($ch); goto mhBu2; Jv25Y: curl_close($ch); goto QZoWj; vO_Kn: curl_setopt($ch, CURLOPT_TIMEOUT, 20); goto K0Kkc; i4L50: curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE); goto gxqkH; zBa46: curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); goto ZgRhX; TqGSk: Yz33U: goto thbyO; W6HOM: CSUTx: goto zBa46; gxqkH: curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, FALSE); goto YovZJ; YovZJ: if (empty($data)) { goto CSUTx; } goto JNQpV; qp8S6: c83n9: goto jwroj; jwroj: $s = '{"success": false,"msg":"' . curl_error($ch) . '" }'; goto RlfeX; oECYi: goto Yz33U; goto qp8S6; l8gn1: curl_setopt($ch, CURLOPT_URL, $url); goto i4L50; ZgRhX: curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1); goto vO_Kn; mb0_B: curl_setopt($ch, CURLOPT_POSTFIELDS, $data); goto W6HOM; JNQpV: curl_setopt($ch, CURLOPT_POST, 1); goto mb0_B; RlfeX: return $s; goto TqGSk; thbyO: } public function doReplacecon($content, $msgtype, $istuwen = 0) { goto Idcgz; Idcgz: if (!($istuwen == 0)) { goto UdVum; } goto wG8o5; v8vuC: WlDhe: goto JuF2m; L_Yc8: B9ZwG: goto vankP; xz326: foreach ($array2[0] as $kk => $vv) { goto vyj9Z; YkVWM: dHYFx: goto Gvq3J; vyj9Z: if (empty($vv)) { goto fAc9W; } goto U05Lr; vjwaE: fAc9W: goto YkVWM; U05Lr: $content = str_replace($vv, '<a href=\'' . $vv . '\'>' . $vv . '</a>', $content); goto vjwaE; Gvq3J: } goto ko1iG; zOWkP: preg_match_all($regex, $content, $array2); goto YB1uZ; CDiSH: $content = '<img src="' . $content . '" />'; goto v8vuC; ko1iG: DA5kc: goto L_Yc8; YB1uZ: if (!(!empty($array2[0]) && ($msgtype == 1 || $msgtype == 2))) { goto B9ZwG; } goto xz326; b_CHW: if (!($msgtype == 3 || $msgtype == 4)) { goto WlDhe; } goto CDiSH; vankP: UdVum: goto b_CHW; wG8o5: $content = $this->guolv($content); goto yJhiZ; JuF2m: return htmlspecialchars_decode($content); goto Kakjs; yJhiZ: $regex = '@(?i)\\b((?:[a-z][\\w-]+:(?:/{1,3}|[a-z0-9%])|www\\d{0,3}[.]|[a-z0-9.\\-]+[.][a-z]{2,4}/)(?:[^\\s()<>]+|\\(([^\\s()<>]+|(\\([^\\s()<>]+\\)))*\\))+(?:\\(([^\\s()<>]+|(\\([^\\s()<>]+\\)))*\\)|[^\\s`!()\\[\\]{};:\'".,<>?]))@'; goto zOWkP; Kakjs: } public function guolv($content) { goto ABReD; nT3dg: foreach ($sensitivewordarr as $k => $v) { goto jlWdI; jlWdI: if (empty($v)) { goto itojW; } goto tneNy; JJWbX: itojW: goto gODc8; gODc8: ksyW3: goto jVSS_; tneNy: $content = str_replace($v, '***', $content); goto JJWbX; jVSS_: } goto n8RKa; byvNE: oP0DL: goto sr62L; CJscd: return $content; goto co5_O; sOqEI: if (empty($mingan)) { goto oP0DL; } goto N9mBD; N9mBD: $sensitivewordarr = explode('|', $mingan); goto nT3dg; ABReD: $mingan = $this->getmoduleconfig('mingan'); goto sOqEI; n8RKa: svjhl: goto byvNE; sr62L: $content = str_replace('
', '<br>', $content); goto CJscd; co5_O: } public function get_os() { goto hRgW1; XfY29: if (preg_match('/mac/i', $os)) { goto ig80P; } goto nAuVL; wtZTE: Ozrvc: goto MawRP; p_F3Q: TF3BH: goto h9_FS; n6G8y: DfTH4: goto goYhS; YyXgt: if (preg_match('/win/i', $os)) { goto Ozrvc; } goto XfY29; MawRP: $os = 'Windows'; goto jCBW0; ePJtT: return $os; goto p_F3Q; D_qsv: goto oRzpb; goto v0_p7; X5TSi: goto TF3BH; goto t02ky; A5Mwi: goto CJqbM; goto wtZTE; O0xB8: $os = $_SERVER['HTTP_USER_AGENT']; goto YyXgt; hRgW1: if (!empty($_SERVER['HTTP_USER_AGENT'])) { goto q0LLy; } goto L2C5a; t02ky: q0LLy: goto O0xB8; uMjMo: $os = 'BSD'; goto fVipP; hqZ79: $os = 'MAC'; goto gK6vM; EtIdm: pYC52: goto PRLLE; X4N13: JdN1m: goto NGai5; IJ69S: DUyqu: goto Ni3Xm; zJtPc: if (preg_match('/unix/i', $os)) { goto pYC52; } goto TndnE; L2C5a: return 'unknow'; goto X5TSi; TndnE: if (preg_match('/bsd/i', $os)) { goto UJN_j; } goto NA6Dz; NA6Dz: $os = 'Other'; goto D_qsv; jCBW0: CJqbM: goto ePJtT; NGai5: $os = 'Linux'; goto n6G8y; fVipP: oRzpb: goto RpWQW; Ni3Xm: goto DfTH4; goto X4N13; PRLLE: $os = 'Unix'; goto IJ69S; nAuVL: if (preg_match('/linux/i', $os)) { goto JdN1m; } goto zJtPc; v0_p7: UJN_j: goto uMjMo; RpWQW: goto DUyqu; goto EtIdm; goYhS: goto c380s; goto XvYU2; XvYU2: ig80P: goto hqZ79; gK6vM: c380s: goto A5Mwi; h9_FS: } public function browse_info() { goto v_xrf; f3dl2: gFkF_: goto xeKaK; TNZ_Z: AZqgN: goto ZGf_v; xeKaK: goto npSBE; goto UD5yl; EoeJ7: eSup9: goto raCVw; PKqJl: w1P1d: goto wkLHE; rWMoF: $br = 'Other'; goto N9GI0; UD5yl: NCsGj: goto NIsRy; jE1ly: xrafI: goto izYSu; izYSu: $br = $_SERVER['HTTP_USER_AGENT']; goto RvYOt; l5TNl: v9UK3: goto HtvU3; ZGf_v: goto v9UK3; goto UnyRN; UnyRN: WZgVI: goto S7wg7; B0knz: return 'unknow'; goto aYgEX; N9GI0: goto eSup9; goto BBYZo; wkLHE: $br = 'Safari'; goto f3dl2; Rzqyp: $br = 'Opera'; goto EoeJ7; ShmCm: if (preg_match('/Chrome/i', $br)) { goto NCsGj; } goto jFAGq; jFAGq: if (preg_match('/Safari/i', $br)) { goto w1P1d; } goto HQ36A; RvYOt: if (preg_match('/MSIE/i', $br)) { goto WZgVI; } goto OKYSB; NIsRy: $br = 'Chrome'; goto kuWdW; HQ36A: if (preg_match('/Opera/i', $br)) { goto yffKP; } goto rWMoF; OKYSB: if (preg_match('/Firefox/i', $br)) { goto PVb5b; } goto ShmCm; aYgEX: goto Xe4KQ; goto jE1ly; di8FL: $br = 'Firefox'; goto TNZ_Z; raCVw: goto gFkF_; goto PKqJl; v_xrf: if (!empty($_SERVER['HTTP_USER_AGENT'])) { goto xrafI; } goto B0knz; kuWdW: npSBE: goto jsE9L; IWFZv: Xe4KQ: goto EfATH; BBYZo: yffKP: goto Rzqyp; NFITQ: PVb5b: goto di8FL; S7wg7: $br = 'MSIE'; goto l5TNl; jsE9L: goto AZqgN; goto NFITQ; HtvU3: return $br; goto IWFZv; EfATH: } public function curl_post2($url = "", $path = "") { goto rFhqo; yqee_: curl_setopt($curl, CURLOPT_URL, $url); goto Onkpc; yAGQt: Csazs: goto kZ_SE; kZ_SE: curl_setopt($curl, CURLOPT_SAFE_UPLOAD, true); goto FtbDy; O5n0n: j38_y: goto yqee_; FtbDy: $data = array("media" => new CURLFile($path)); goto O5n0n; zab4W: $data = array("media" => '@' . $path); goto DoG3u; Bbqel: $res = json_decode($result, true); goto crfST; crfST: return $res; goto iewOg; GaRaW: curl_setopt($curl, CURLOPT_SAFE_UPLOAD, false); goto zab4W; cTeDz: curl_setopt($curl, CURLOPT_USERAGENT, 'TEST'); goto wnt2j; rFhqo: $curl = curl_init(); goto MCGBK; MCGBK: if (class_exists('CURLFile')) { goto Csazs; } goto GaRaW; DoG3u: goto j38_y; goto yAGQt; jq2Hq: curl_setopt($curl, CURLOPT_POSTFIELDS, $data); goto RSojY; Onkpc: curl_setopt($curl, CURLOPT_POST, 1); goto jq2Hq; RSojY: curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1); goto cTeDz; wnt2j: $result = curl_exec($curl); goto Bbqel; iewOg: } public function get_lang() { goto C3b78; ib8bS: if (preg_match('/zh/i', $lang)) { goto AF5xb; } goto PEVJn; FZvwZ: $lang = $_SERVER['HTTP_ACCEPT_LANGUAGE']; goto aLCbh; G09hI: return $lang; goto atbrH; EzY34: oa2e1: goto RuelN; Y5LIV: return 'unknow'; goto XCkuu; XCkuu: goto f0Zg2; goto hIh8r; C3b78: if (!empty($_SERVER['HTTP_ACCEPT_LANGUAGE'])) { goto So_TV; } goto Y5LIV; Ja54w: inmBf: goto G09hI; RuelN: goto inmBf; goto ik3Eh; atbrH: f0Zg2: goto KZ0Q_; PEVJn: $lang = 'English'; goto SyJV6; P8lAC: $lang = ''; goto Ja54w; aLCbh: $lang = substr($lang, 0, 5); goto GATro; ik3Eh: bNBML: goto P8lAC; KjmEI: AF5xb: goto FHnJk; SyJV6: goto oa2e1; goto KjmEI; GATro: if (preg_match('/zh-cn/i', $lang)) { goto bNBML; } goto ib8bS; FHnJk: $lang = ''; goto EzY34; hIh8r: So_TV: goto FZvwZ; KZ0Q_: } } ?>

Function Calls

None

Variables

None

Stats

MD5 cba2aa27534ad8ecfe2baf7fef785ac4
Eval Count 0
Decode Time 125 ms