$connect_member = DB::fetch_first("SELECT * FROM " . DB::table('common_member_connect') . " WHERE uid='{$_G['uid']}'"); if ($connect_member['conuinsecret']) { if ($_G['member']['conisregister']) { if ($_G['gp_newpassword1'] !== $_G['gp_newpassword2']) { showmessage('profile_passwd_notmatch', $referer); } if (!$_G['gp_newpassword1'] || $_G['gp_newpassword1'] != addslashes($_G['gp_newpassword1'])) { showmessage('profile_passwd_illegal', $referer); } } $response = connect_user_unbind(); if (!isset($response['status']) || $response['status'] !== 0) { if (!isset($response['status'])) { connect_errlog('100', lang('connect', 'connect_errlog_server_no_response')); } else { connect_errlog($response['status'], $response['result']); } } } else { if ($_G['member']['conisregister']) { if ($_G['gp_newpassword1'] !== $_G['gp_newpassword2']) { showmessage('profile_passwd_notmatch', $referer); } if (!$_G['gp_newpassword1'] || $_G['gp_newpassword1'] != addslashes($_G['gp_newpassword1'])) { showmessage('profile_passwd_illegal', $referer); } } } DB::query("UPDATE " . DB::table('common_member_connect') . " SET conuin='', conuinsecret='', conopenid='', conispublishfeed='0', conispublisht='0', conisregister='0', conisqzoneavatar='0', conisfeed='0' WHERE uid='{$_G['uid']}'"); DB::query("UPDATE " . DB::table('common_member') . " SET conisbind='0' WHERE uid='{$_G['uid']}'"); DB::query("INSERT INTO " . DB::table('connect_memberbindlog') . " (uid, uin, type, dateline) VALUES ('{$_G['uid']}', '{$_G[member][conopenid]}', '2', '{$_G['timestamp']}')");
$params['content'] = $_G['gp_html_content']; $params['client_ip'] = $_G['clientip']; $params['attach_images'] = $_G['gp_attach_image']; $params = array_merge($sig_params, $params); $response = connect_output_php($api_url . '?', cloud_http_build_query($params, '', '&')); if (!isset($response['status'])) { $code = 100; connect_errlog($code, lang('connect', 'connect_errlog_server_no_response')); $message = lang('connect', 'server_busy'); } else { if ($response['status'] == 0) { $code = $response['status']; if ($sh_type == 2) { $message = lang('connect', 'broadcast_success'); } else { $message = lang('connect', 'share_success'); } } else { $message = lang('connect', 'server_busy'); $code = $response['status']; if ($response['status'] == 6022 || $response['status'] == 6023 || $response['status'] == 6029) { $message = $response['result']; connect_errlog($code, $message); } elseif ($response['status'] == 20000) { $message = lang('connect', 'user_unauthorized'); } elseif ($response['status'] == 30000) { $message = lang('connect', 'weibo_account_not_signup'); } } } }