function showsendsms() { global $_G; global $lang; global $Plang; showtablerow('', array('class="th12"', ''), array($Plang['smstong_members_qunfasms_content'], '<a href="' . ADMINSCRIPT . '?action=plugins&operation=config&do=' . $pluginid . '&identifier=smstong&pmod=qunfasms&getmobile=true">' . $Plang['smstong_members_qunfasms_getmobile'] . '</a><br /><br /><textarea name="message" cols="100" rows="10">' . $_G['gp_content'] . '</textarea>')); showtablerow('', array('class="th12"', ''), array('', '<strong>' . $Plang['smstong_members_qunfasms_notice'] . '</strong>')); }
public function showPlugins() { global $_G; $plugins = array(); $identifiers = array('qqconnect', 'cloudstat', 'soso_smilies', 'cloudsearch', 'qqgroup', 'security', 'xf_storage'); $plugins = C::t('common_plugin')->fetch_all_by_identifier($identifiers); if ($plugins && count($plugins) == count($identifiers)) { $systemPluginStatus = cplang('cloud_doctor_result_success') . ' ' . cplang('available') . ' ' . cplang('cloud_doctor_system_plugin_list'); } else { $initsysFormHash = substr(md5(substr($_G['timestamp'], 0, -7) . $_G['username'] . $_G['uid'] . $_G['authkey']), 8, 8); $systemPluginStatus = cplang('cloud_doctor_result_failure') . cplang('cloud_doctor_system_plugin_status_false', array('formhash' => $initsysFormHash)); } showtablerow('', array('class="td24"'), array('<strong>' . cplang('cloud_doctor_system_plugin_status') . '</strong>', $systemPluginStatus)); foreach ($plugins as $plugin) { $moduleStatus = cplang('cloud_doctor_plugin_module_error'); $plugin['modules'] = @dunserialize($plugin['modules']); if (is_array($plugin['modules']) && $plugin['modules']) { $moduleStatus = ''; } showtablerow('', array('class="td24"'), array('<strong>' . $plugin['name'] . '</strong>', cplang('version') . ' ' . $plugin['version'] . ' ' . $moduleStatus)); } }
if (!defined('IN_ADMINCP')) { exit('Access Denied'); } include_once DISCUZ_ROOT . './source/plugin/dsu_updater/core.func.php'; showtableheader($du_lang['installed_plugin']); showsubtitle(array($du_lang['plugin_name'], $du_lang['ver_installed'], $du_lang['ver_new'], $du_lang['action'])); $query = DB::query('SELECT name,identifier,version FROM ' . DB::table('common_plugin') . " WHERE identifier LIKE 'dsu_%'"); while ($result = DB::fetch($query)) { $output = array(); $output[] = $result['name']; $output[] = $result['version']; $plugin[$result['identifier']] = $result['name']; $output[] = $_G['dsu_updater']['plugin'][$result['identifier']]; if ($result['version'] == $_G['dsu_updater']['plugin'][$result['identifier']] || $_G['dsu_updater']['plugin'][$result['identifier']] == '') { $output[] = ''; } else { $output[] = '<a href="admin.php?action=plugins&operation=config&identifier=dsu_updater&pmod=main&plugin=' . $result['identifier'] . '&formhash=' . FORMHASH . "\">{$du_lang[update_do]}</a>"; } showtablerow('', '', $output); } showtablefooter(); if (submitcheck('plugin', 1)) { showtableheader($du_lang['update_status'] . $plugin[$_G['gp_plugin']]); echo '<tr><td class="tipsblock"><ul id="update_status"><li>正在请求 Callback 系统, 请稍候...</li></ul></td></tr>'; showtablefooter(); @(include_once DISCUZ_ROOT . './source/discuz_version.php'); echo '<script onerror="document.getElementById(\'update_status\').innerHTML+=\'<li><font color=red>发送 CallBack 数据失败.</font></li>\'" src="http://update.dsu.cc/plugin.php?id=' . $_G['gp_plugin'] . '&site_id=' . $_G['dsu_updater']['site_id'] . '&keyhash=' . md5($_G['dsu_updater']['key']) . '&dv=' . DISCUZ_VERSION . '"></script>'; } @(include_once DISCUZ_ROOT . './source/discuz_version.php'); callback('plugin', 0, '&dv=' . DISCUZ_VERSION);
function recyclebinpostshowpostlist($fid, $authors, $starttime, $endtime, $keywords, $start_limit, $lpp) { global $_G, $lang, $posttableid, $security; $tids = $fids = array(); if ($security) { $postlist = C::t('#security#security_evilpost')->fetch_all_by_search($posttableid, null, $keywords, -5, $fid, null, $authors ? explode(',', str_replace(' ', '', $authors)) : null, strtotime($starttime), strtotime($endtime), null, null, $start_limit, $lpp); } else { $postlist = C::t('forum_post')->fetch_all_by_search($posttableid, null, $keywords, -5, $fid, null, $authors ? explode(',', str_replace(' ', '', $authors)) : null, strtotime($starttime), strtotime($endtime), null, null, $start_limit, $lpp); } if (empty($postlist)) { return false; } foreach ($postlist as $key => $post) { $tids[$post['tid']] = $post['tid']; $fids[$post['fid']] = $post['fid']; } foreach (C::t('forum_thread')->fetch_all_by_tid($tids) as $thread) { $thread['tsubject'] = $thread['subject']; $threadlist[$thread['tid']] = $thread; } $query = C::t('forum_forum')->fetch_all_by_fid($fids); foreach ($query as $val) { $forum = array('fid' => $val['fid'], 'forumname' => $val['name'], 'allowsmilies' => $val['allowsmilies'], 'allowhtml' => $val['allowhtml'], 'allowbbcode' => $val['allowbbcode'], 'allowimgcode' => $val['allowimgcode']); $forumlist[$forum['fid']] = $forum; } foreach ($postlist as $key => $post) { $post['message'] = discuzcode($post['message'], $post['smileyoff'], $post['bbcodeoff'], sprintf('%00b', $post['htmlon']), $forumlist[$post['fid']]['allowsmilies'], $forumlist[$post['fid']]['allowbbcode'], $forumlist[$post['fid']]['allowimgcode'], $forumlist[$post['fid']]['allowhtml']); $post['dateline'] = dgmdate($post['dateline']); if ($post['attachment']) { require_once libfile('function/attachment'); foreach (C::t('forum_attachment_n')->fetch_all_by_id('tid:' . $post['tid'], 'pid', $post['pid']) as $attach) { $_G['setting']['attachurl'] = $attach['remote'] ? $_G['setting']['ftp']['attachurl'] : $_G['setting']['attachurl']; $attach['url'] = $attach['isimage'] ? " {$attach['filename']} (" . sizecount($attach['filesize']) . ")<br /><br /><img src=\"" . $_G['setting']['attachurl'] . "forum/{$attach['attachment']}\" onload=\"if(this.width > 100) {this.resized=true; this.width=100;}\">" : "<a href=\"" . $_G['setting']['attachurl'] . "forum/{$attach['attachment']}\" target=\"_blank\">{$attach['filename']}</a> (" . sizecount($attach['filesize']) . ")"; $post['message'] .= "<br /><br />{$lang['attachment']}: " . attachtype(fileext($attach['filename']) . "\t") . $attach['url']; } } showtablerow("id=\"mod_{$post['pid']}_row1\"", array('rowspan="3" class="rowform threadopt" style="width:80px;"', 'class="threadtitle"'), array("<ul class=\"nofloat\"><li><input class=\"radio\" type=\"radio\" name=\"moderate[{$post['pid']}]\" id=\"mod_{$post['pid']}_1\" value=\"delete\" checked=\"checked\" /><label for=\"mod_{$post['pid']}_1\">{$lang['delete']}</label></li><li><input class=\"radio\" type=\"radio\" name=\"moderate[{$post['pid']}]\" id=\"mod_{$post['pid']}_2\" value=\"undelete\" /><label for=\"mod_{$post['pid']}_2\">{$lang['undelete']}</label></li><li><input class=\"radio\" type=\"radio\" name=\"moderate[{$post['pid']}]\" id=\"mod_{$post['pid']}_3\" value=\"ignore\" /><label for=\"mod_{$post['pid']}_3\">{$lang['ignore']}</label></li></ul>", "<h3><a href=\"forum.php?mod=forumdisplay&fid={$post['fid']}\" target=\"_blank\">" . $forumlist[$post['fid']]['forumname'] . "</a> » <a href=\"forum.php?mod=viewthread&tid={$post['tid']}\" target=\"_blank\">" . $threadlist[$post['tid']]['tsubject'] . "</a>" . ($post['subject'] ? ' » ' . $post['subject'] : '') . "</h3><p><span class=\"bold\">{$lang['author']}:</span> <a href=\"home.php?mod=space&uid={$post['authorid']}\" target=\"_blank\">{$post['author']}</a> <span class=\"bold\">{$lang['time']}:</span> {$post['dateline']} IP: {$post['useip']}</p>")); showtablerow("id=\"mod_{$post['pid']}_row2\"", 'colspan="2" style="padding: 10px; line-height: 180%;"', '<div style="overflow: auto; overflow-x: hidden; max-height:120px; height:auto !important; height:120px; word-break: break-all;">' . $post['message'] . '</div>'); showtablerow("id=\"mod_{$post['pid']}_row3\"", 'class="threadopt threadtitle" colspan="2"', "{$lang['isanonymous']}: " . ($post['anonymous'] ? $lang['yes'] : $lang['no']) . " {$lang['ishtmlon']}: " . ($post['htmlon'] ? $lang['yes'] : $lang['no'])); } return true; }
showformfooter(); } else { showsubtitle(array('block_name', 'block_script', 'block_style', 'block_dateline', 'block_page', 'operation')); $multipage = ''; $count = DB::result(DB::query("SELECT COUNT(*) FROM " . DB::table('common_block') . " b LEFT JOIN " . DB::table('common_template_block') . " tb ON tb.bid=b.bid WHERE {$wheresql}"), 0); if ($count) { $query = DB::query("SELECT b.*, tb.targettplname FROM " . DB::table('common_block') . " b LEFT JOIN " . DB::table('common_template_block') . " tb ON b.bid=tb.bid WHERE {$wheresql} {$ordersql} LIMIT {$start},{$perpage}"); while ($value = DB::fetch($query)) { if ($value['targettplname']) { $diyurl = block_getdiyurl($value['targettplname']); $diyurl = $diyurl['url']; $tplname = isset($_G['cache']['diytemplatename'][$value['targettplname']]) ? $_G['cache']['diytemplatename'][$value['targettplname']] : $value['targettplname']; $diypage[$value['bid']][$value['targettplname']] = $diyurl ? '<a href="' . $diyurl . '" target="_blank">' . $tplname . '</a>' : $tplname; } $list[$value['bid']] = $value; } if ($list) { foreach ($list as $bid => $value) { $inpage = empty($diypage[$bid]) ? cplang('block_page_unused') : implode('<br/>', $diypage[$bid]); $theclass = block_getclass($value['blockclass'], true); showtablerow('', '', array($value['name'] ? $value['name'] : cplang('block_name_null'), $theclass['script'][$value['script']], $value['styleid'] ? $theclass['style'][$value['styleid']]['name'] : lang('portalcp', 'blockstyle_diy'), !empty($value['dateline']) ? dgmdate($value['dateline']) : cplang('block_dateline_null'), $inpage, "<a href=\"portal.php?mod=portalcp&ac=block&op=block&bid={$value['bid']}&from=cp\" target=\"_blank\" onclick=\"showWindow('showblock',this.href);return false;\">" . cplang('block_setting') . "</a>  " . "<a href=\"portal.php?mod=portalcp&ac=block&op=data&bid={$value['bid']}&from=cp\" target=\"_blank\" onclick=\"showWindow('showblock',this.href);return false;\">" . cplang('block_data') . "</a>  " . $diyop . " <a href=\"" . ADMINSCRIPT . "?action=block&operation=perm&bid={$value['bid']}\">" . cplang('portalcategory_perm') . '</a>')); } } $multipage = multi($count, $perpage, $page, $mpurl); } showsubmit('', '', '', '<input type="submit" class="btn" name="clearsubmit" value="' . cplang('block_clear_unused') . '" />', $multipage); showtablefooter(); showformfooter(); } } }
$shareurl = "home.php?mod=space&uid={$share['fromuid']}&do=blog&id={$share['itemid']}&modblogkey={$share['modkey']}"; $sharetitle = lang('admincp', 'share_type_blog'); break; case 'album': $shareurl = "home.php?mod=space&uid={$share['fromuid']}&do=album&id={$share['itemid']}&modalbumkey={$share['modkey']}"; $sharetitle = lang('admincp', 'share_type_album'); break; case 'article': $shareurl = "portal.php?mod=view&aid={$share['itemid']}&modarticlekey={$share['modkey']}"; $sharetitle = lang('admincp', 'share_type_article'); break; } showtagheader('tbody', '', true, 'hover'); showtablerow("id=\"mod_{$share['sid']}_row1\"", array("id=\"mod_{$share['sid']}_row1_op\" rowspan=\"3\" class=\"rowform threadopt\" style=\"width:80px;\"", '', 'width="120"', 'width="120"', 'width="55"', 'width="55"'), array("<ul class=\"nofloat\"><li><input class=\"radio\" type=\"radio\" name=\"moderate[{$share['sid']}]\" id=\"mod_{$share['sid']}_1\" value=\"validate\" onclick=\"mod_setbg({$share['sid']}, 'validate');\"><label for=\"mod_{$share['sid']}_1\">{$lang['validate']}</label></li><li><input class=\"radio\" type=\"radio\" name=\"moderate[{$share['sid']}]\" id=\"mod_{$share['sid']}_2\" value=\"delete\" onclick=\"mod_setbg({$share['sid']}, 'delete');\"><label for=\"mod_{$share['sid']}_2\">{$lang['delete']}</label></li><li><input class=\"radio\" type=\"radio\" name=\"moderate[{$share['sid']}]\" id=\"mod_{$doing['doid']}_3\" value=\"ignore\" onclick=\"mod_setbg({$share['sid']}, 'ignore');\"><label for=\"mod_{$share['sid']}_3\">{$lang['ignore']}</label></li></ul>", "<h3><a href=\"javascript:;\" onclick=\"display_toggle({$share[sid]});\">{$short_desc} {$share_censor_text}</a></h3>", $sharetitle, "<p><a target=\"_blank\" href=\"" . ADMINSCRIPT . "?action=members&operation=search&uid={$share['uid']}&submit=yes\">{$share['username']}</a></p> <p>{$share['dateline']}</p>", "<a target=\"_blank\" href=\"{$shareurl}\">{$lang['view']}</a>")); showtablerow("id=\"mod_{$share['sid']}_row2\"", 'colspan="4" style="padding: 10px; line-height: 180%;"', '<div style="overflow: auto; overflow-x: hidden; max-height:120px; height:auto !important; height:100px; word-break: break-all;">' . $share['body_general'] . '</div>'); showtablerow("id=\"mod_{$share['sid']}_row3\"", 'class="threadopt threadtitle" colspan="4"', "<a href=\"?action=moderate&operation=shares&fast=1&sid={$share['sid']}&moderate[{$share['sid']}]=validate&page={$page}&frame=no\" target=\"fasthandle\">{$lang['validate']}</a> | <a href=\"?action=moderate&operation=shares&fast=1&sid={$share['sid']}&moderate[{$share['sid']}]=delete&page={$page}&frame=no\" target=\"fasthandle\">{$lang['delete']}</a> | <a href=\"?action=moderate&operation=shares&fast=1&sid={$share['sid']}&moderate[{$share['sid']}]=ignore&page={$page}&frame=no\" target=\"fasthandle\">{$lang['ignore']}</a>"); showtagfooter('tbody'); } showsubmit('modsubmit', 'submit', '', '<a href="#all" onclick="mod_setbg_all(\'validate\')">' . cplang('moderate_all_validate') . '</a> <a href="#all" onclick="mod_setbg_all(\'delete\')">' . cplang('moderate_all_delete') . '</a> <a href="#all" onclick="mod_setbg_all(\'ignore\')">' . cplang('moderate_all_ignore') . '</a> <a href="#all" onclick="mod_cancel_all();">' . cplang('moderate_all_cancel') . '</a>', $multipage, false); showtablefooter(); showformfooter(); } else { $moderation = array('validate' => array(), 'delete' => array(), 'ignore' => array()); $validates = $deletes = $ignores = 0; if (is_array($moderate)) { foreach ($moderate as $sid => $act) { $moderation[$act][] = $sid; } } if (!empty($moderation['validate'])) { require_once libfile('function/feed');
if ($processed) { cpmsg("{$lang['counter_thread_cover']}: " . cplang('counter_processing', array('current' => $current, 'next' => $next)), $nextlink, 'loading'); } else { cpmsg('counter_thread_cover_succeed', 'action=counter', 'succeed'); } } else { shownav('tools', 'nav_updatecounters'); showsubmenu('nav_updatecounters'); showtips('counter_tips'); showformheader('counter'); showtableheader(); showsubtitle(array('', 'counter_amount')); showhiddenfields(array('pertask' => '')); showtablerow('', array('class="td21"'), array("{$lang['counter_forum']}:", '<input name="pertask1" type="text" class="txt" value="15" /><input type="submit" class="btn" name="forumsubmit" onclick="this.form.pertask.value=this.form.pertask1.value" value="' . $lang['submit'] . '" />')); showtablerow('', array('class="td21"'), array("{$lang['counter_digest']}:", '<input name="pertask2" type="text" class="txt" value="1000" /><input type="submit" class="btn" name="digestsubmit" onclick="this.form.pertask.value=this.form.pertask2.value" value="' . $lang['submit'] . '" />')); showtablerow('', array('class="td21"'), array("{$lang['counter_member']}:", '<input name="pertask3" type="text" class="txt" value="1000" /><input type="submit" class="btn" name="membersubmit" onclick="this.form.pertask.value=this.form.pertask3.value" value="' . $lang['submit'] . '" />')); showtablerow('', array('class="td21"'), array("{$lang['counter_thread']}:", '<input name="pertask4" type="text" class="txt" value="500" /><input type="submit" class="btn" name="threadsubmit" onclick="this.form.pertask.value=this.form.pertask4.value" value="' . $lang['submit'] . '" />')); showtablerow('', array('class="td21"'), array("{$lang['counter_special']}:", '<input name="pertask7" type="text" class="txt" value="1" disabled/><input type="submit" class="btn" name="specialarrange" onclick="this.form.pertask.value=this.form.pertask7.value" value="' . $lang['submit'] . '" />')); showtablerow('', array('class="td21"'), array("{$lang['counter_groupnum']}:", '<input name="pertask8" type="text" class="txt" value="10" /><input type="submit" class="btn" name="groupnum" onclick="this.form.pertask.value=this.form.pertask8.value" value="' . $lang['submit'] . '" />')); showtablerow('', array('class="td21"'), array("{$lang['counter_groupmember_num']}:", '<input name="pertask9" type="text" class="txt" value="100" /><input type="submit" class="btn" name="groupmembernum" onclick="this.form.pertask.value=this.form.pertask9.value" value="' . $lang['submit'] . '" />')); showtablerow('', array('class="td21"'), array("{$lang['counter_groupmember_post']}:", '<input name="pertask10" type="text" class="txt" value="100" /><input type="submit" class="btn" name="groupmemberpost" onclick="this.form.pertask.value=this.form.pertask10.value" value="' . $lang['submit'] . '" />')); showtablerow('', array('class="td21"'), array("{$lang['counter_blog_replynum']}:", '<input name="pertask11" type="text" class="txt" value="100" /><input type="submit" class="btn" name="blogreplynum" onclick="this.form.pertask.value=this.form.pertask11.value" value="' . $lang['submit'] . '" />')); showtablerow('', array('class="td21"'), array("{$lang['counter_friendnum']}:", '<input name="pertask12" type="text" class="txt" value="100" /><input type="submit" class="btn" name="friendnum" onclick="this.form.pertask.value=this.form.pertask12.value" value="' . $lang['submit'] . '" />')); showtablerow('', array('class="td21"'), array("{$lang['counter_album_picnum']}:", '<input name="pertask13" type="text" class="txt" value="100" /><input type="submit" class="btn" name="albumpicnum" onclick="this.form.pertask.value=this.form.pertask13.value" value="' . $lang['submit'] . '" />')); showtablerow('', array('class="td21"'), array("{$lang['counter_thread_cover']}:", '<script type="text/javascript" src="static/js/calendar.js"></script><input name="pertask14" type="text" class="txt" value="100" /> ' . $lang['counter_forumid'] . ': <input type="text" class="txt" name="fid" value="" size="10"> <input type="checkbox" value="1" name="allthread">' . $lang['counter_have_cover'] . '<br><input type="text" onclick="showcalendar(event, this)" value="" name="starttime" class="txt"> -- <input type="text" onclick="showcalendar(event, this)" value="" name="endtime" class="txt">(' . $lang['counter_thread_cover_settime'] . ') <input type="submit" class="btn" name="setthreadcover" onclick="this.form.pertask.value=this.form.pertask14.value" value="' . $lang['submit'] . '" />')); showtablefooter(); showformfooter(); } function runuchcount($start, $perpage) { }
* $Id: admincp_templates.php 6757 2010-03-25 09:01:29Z cnteacher $ */ if (!defined('IN_DISCUZ') || !defined('IN_ADMINCP')) { exit('Access Denied'); } cpheader(); if (!isfounder()) { cpmsg('noaccess_isfounder', '', 'error'); } $operation = empty($operation) ? 'admin' : $operation; if ($operation == 'admin') { if (!submitcheck('tplsubmit')) { $templates = ''; $query = DB::query("SELECT * FROM " . DB::table('common_template') . ""); while ($tpl = DB::fetch($query)) { $templates .= showtablerow('', array('class="td25"', '', 'class="td29"'), array("<input class=\"checkbox\" type=\"checkbox\" name=\"delete[]\" " . ($tpl['templateid'] == 1 ? 'disabled ' : '') . "value=\"{$tpl['templateid']}\">", "<input type=\"text\" class=\"txt\" size=\"8\" name=\"namenew[{$tpl['templateid']}]\" value=\"{$tpl['name']}\">", "<input type=\"text\" class=\"txt\" size=\"20\" name=\"directorynew[{$tpl['templateid']}]\" value=\"{$tpl['directory']}\">", !empty($tpl['copyright']) ? $tpl['copyright'] : "<input type=\"text\" class=\"txt\" size=\"8\" name=\"copyrightnew[{$tpl['templateid']}]\" value=>"), TRUE); } shownav('style', 'templates_admin'); showsubmenu('templates_admin'); showformheader('templates'); showtableheader(); showsubtitle(array('', 'templates_admin_name', 'dir', 'copyright', '')); echo $templates; echo '<tr><td>' . $lang['add_new'] . '</td><td><input type="text" class="txt" size="8" name="newname"></td><td class="td29"><input type="text" class="txt" size="20" name="newdirectory"></td><td><input type="text" class="txt" size="25" name="newcopyright"></td><td> </td></tr>'; showsubmit('tplsubmit', 'submit', 'del'); showtablefooter(); showformfooter(); } else { if ($_G['gp_newname']) { if (!$_G['gp_newdirectory']) { cpmsg('tpl_new_directory_invalid', '', 'error');
$order['orderstatus'] = $lang['ec_orders_search_status_pending']; break; case 2: $order['orderstatus'] = '<b>' . $lang['ec_orders_search_status_auto_finished'] . '</b>'; break; case 3: $order['orderstatus'] = '<b>' . $lang['ec_orders_search_status_manual_finished'] . '</b><br />(<a href="home.php?mod=space&username='******'admin']) . '" target="_blank">' . $order['admin'] . '</a>)'; break; } $order['submitdate'] = dgmdate($order['submitdate']); $order['confirmdate'] = $order['confirmdate'] ? dgmdate($order['confirmdate']) : 'N/A'; list($orderid, $apitype) = explode("\t", $order['buyer']); $apitype = $apitype ? $apitype : 'alipay'; $orderid = '<a href="' . $orderurl[$apitype] . $orderid . '" target="_blank">' . $orderid . '</a>'; showtablerow('', '', array("<input class=\"checkbox\" type=\"checkbox\" name=\"validate[]\" value=\"{$order['orderid']}\" " . ($order['status'] != 1 ? 'disabled' : '') . ">", "{$order['orderid']}<br />{$orderid}", $order['orderstatus'], "{$order['email']}<br>{$order['ip']}", $order['amount'], "{$lang['rmb']} {$order['price']} {$lang['rmb_yuan']}", $order['submitdate'], $order['confirmdate'])); } showtablerow('', array('colspan="7"'), array($multipage)); showsubmit('ordersubmit', 'ec_orders_validate', '<input type="checkbox" name="chkall" id="chkall" class="checkbox" onclick="checkAll(\'prefix\', this.form, \'validate\')" />'); showtablefooter(); showformfooter(); showtagfooter('div'); } else { if ($_G['gp_validate']) { $query = DB::query("SELECT * FROM " . DB::table('forum_order') . " WHERE orderid IN (" . dimplode($_G['gp_validate']) . ") AND status='1'"); if ($numvalidate = DB::num_rows($query)) { DB::query("UPDATE " . DB::table('forum_order') . " SET status='3', admin='{$_G['username']}', confirmdate='{$_G['timestamp']}' WHERE orderid IN (" . dimplode($_G['gp_validate']) . ")"); } } cpmsg('orders_validate_succeed', "action=ec&operation=inviteorders&orderstatus={$_G['gp_orderstatus']}&orderid={$_G['gp_orderid']}&email={$_G['gp_email']}", 'succeed'); } }
} $managelog = $managelogarr = array(); $tpp = 15; $page = $_GET['page'] > 0 ? intval($_GET['page']) : 1; $mlstart = ($page - 1) * $tpp; $query = DB::query("SELECT count(mlogid) AS count FROM " . tname('managelog') . $wheresql . ";"); $value = DB::fetch($query); foreach ($_GET as $key => $_value) { if (in_array($key, array('action', 'formhash', 'filtersubmit', 'managelogtype', 'shopid'))) { $url .= '&' . $key . '=' . $_value; } } $url = '?' . substr($url, 1); $multipage = multi($value['count'], $tpp, $page, 'admin.php' . $url, $phpurl = 1); $query = DB::query("SELECT * FROM " . tname('managelog') . $wheresql . " ORDER BY dateline DESC LIMIT " . $mlstart . ", " . $tpp . ";"); while ($managelog = DB::fetch($query)) { $managelog['shopname'] = DB::result_first("SELECT subject FROM " . tname('shopitems') . " WHERE itemid='{$managelog['shopid']}'"); $managelog['itemname'] = DB::result_first("SELECT subject FROM " . tname($managelog['type'] . 'items') . " WHERE itemid='{$managelog['itemid']}'"); $managelog['typename'] = $lang['header_' . $managelog['type']]; $managelog['shortreason'] = cutstr($managelog['reason'], 60, 1); $managelogarr[] = $managelog; } foreach ($managelogarr as $value) { showtablerow('', array(), array($_G['username'], '<a href=\'store.php?id=' . $value['shopid'] . '&action=' . $value['type'] . '&xid=' . $value['itemid'] . '\' target=\'_blank\'>' . $value['itemname'] . '</a>', '<a href=\'store.php?id=' . $value['shopid'] . '\' target=\'_blank\'>' . $value['shopname'] . '</a>', $value['typename'] . $_SGLOBAL['shopgrade'][$value['opcheck']], '<span title="' . $value['reason'] . '">' . $value['shortreason'] . '</span>', date('Y-m-d', $value['dateline']))); } showtablefooter(); echo $multipage; showformfooter(); } else { show_searchform_managelog(); }
!defined('IN_DISCUZ') && exit('Access Denied'); !defined('IN_ADMINCP') && exit('Access Denied'); $setting = $_G['cache']['plugin']['k_gaiming']; if (!submitcheck('submit')) { $count = $start = 0; $perpage = 20; $page = max(1, intval($_GET['page'])); $start = ($page - 1) * $perpage; $count = DB::result_first("SELECT count(*) FROM " . DB::table("plugin_k_gaiming_log")); $query = DB::query("SELECT * FROM " . DB::table("plugin_k_gaiming_log") . " ORDER BY dateline DESC LIMIT " . $start . "," . $perpage); $logs = ''; while ($log = DB::fetch($query)) { $log['dateline'] = dgmdate($log['dateline'], 'u'); $log['username'] = getuserbyuid($log['uid']); $logs .= showtablerow('', array('class="td25"', 'class="td29"', 'class="td28"', 'class="td29"'), array("<input class=\"checkbox\" type=\"checkbox\" name=\"delete[]\" value=\"" . $log['lid'] . "\">", "<a href=\"home.php?mod=space&uid=" . $log['uid'] . "\" target=\"_blank\">" . $log['username']['username'] . "</a> (UID: " . $log['uid'] . ")", "<font color=\"#2366A8\">" . $log['username']['username'] . "</font> " . lang('plugin/k_gaiming', 'logcp_1') . " <font color=\"#2366A8\">" . $log['dateline'] . "</font> " . lang('plugin/k_gaiming', 'logcp_2') . " <font color=\"#2366A8\">" . $log['oldname'] . "</font> " . lang('plugin/k_gaiming', 'logcp_3') . " <font color=\"#2366A8\">" . $log['newname'] . "</font>", $log['creditnum'] . " " . $_G['setting']['extcredits'][$log['creditunit']]['unit'] . $_G['setting']['extcredits'][$log['creditunit']]['title'], $log['dateline']), TRUE); } $multi = multi($count, $perpage, $page, ADMINSCRIPT . "?action=plugins&operation=config&do=" . $pluginid . "&identifier=k_gaiming&pmod=logcp"); showformheader("plugins&operation=config&identifier=k_gaiming&pmod=logcp&page=" . $page, "enctype"); showtableheader(''); showsubtitle(array('', lang('plugin/k_gaiming', 'logcp_6'), lang('plugin/k_gaiming', 'logcp_5'), lang('plugin/k_gaiming', 'logcp_4'), lang('plugin/k_gaiming', 'logcp_7'))); echo $logs; showsubmit('submit', lang('plugin/k_gaiming', 'submit'), 'del', '', $multi); showtablefooter(); showformfooter(); } else { if (is_array($_GET['delete'])) { $ids = dimplode($_GET['delete']); DB::query("DELETE FROM " . DB::table('plugin_k_gaiming_log') . " WHERE lid IN ({$ids})"); } cpmsg(lang('plugin/k_gaiming', 'success'), 'action=plugins&operation=config&identifier=k_gaiming&pmod=logcp&page=' . $page, 'succeed');
[1,\'' . $exsel . '\', ""], [1,\'<input type="text" class="txt" name="reward[]" size="7">\', ""], ]] </script>'; showformheader('plugins&operation=config&identifier=dsu_amupper&pmod=admin'); showtips(lang("plugin/dsu_amupper", "admin2_p1")); showtableheader(lang("plugin/dsu_amupper", "admin2_h1")); showsubtitle(array(lang("plugin/dsu_amupper", "admin2_t0"), lang("plugin/dsu_amupper", "admin2_t1"), lang("plugin/dsu_amupper", "admin2_t4"), lang("plugin/dsu_amupper", "admin2_t2"), lang("plugin/dsu_amupper", "admin2_t3"))); $arr = DB::fetch_all("SELECT * FROM %t WHERE id>%d LIMIT %d", array('plugin_dsuamupperc', '-1', '100'), 'id'); if ($arr) { $i = 0; $data_f2a = dstripslashes($arr); foreach ($data_f2a as $id => $result) { $exsel = extc2seled($result['extcredits'], $_G['setting']['extcredits']); $gidsel = usergroups2seled($result['usergid'], $usergroups); showtablerow('', array(' ', ' ', ' ', ' '), array('<input type="checkbox" class="checkbox" name="delete[]" value="' . $i . '" />', '<INPUT TYPE="hidden" NAME="id[]" value="' . $result['id'] . '"><input type="text" class="txt" name="days[]" value="' . $result['days'] . '" size="7" />', '' . $gidsel . '', '' . $exsel . '', '<input type="text" class="txt" name="reward[]" value="' . $result['reward'] . '" size="7" />')); $i++; } } echo '<tr><td></td><td colspan="3"><div><a href="#addrow" name="addrow" onclick="addrow(this, 0)" class="addtr">' . lang("plugin/dsu_amupper", "admin2_s1") . '</a></div></td></tr>'; showsubmit('submit', lang("plugin/dsu_amupper", "admin2_s2")); showtablefooter(); showformfooter(); } elseif ($_G['adminid'] == '1' && $_GET['formhash'] == FORMHASH) { $mrcs = array(); $max_i = max(count($_GET['days']), count($_GET['usergid']), count($_GET['extcredits']), count($_GET['reward'])); for ($i = 0; $i < $max_i; $i++) { if (intval($_GET['days'][$i]) && intval($_GET['extcredits'][$i]) && intval($_GET['usergid'][$i]) && intval($_GET['reward'][$i] * 100) && !in_array($i, $_GET['delete'])) { $mrcs[$i]['days'] = intval($_GET['days'][$i]); $mrcs[$i]['usergid'] = intval($_GET['usergid'][$i]); $mrcs[$i]['extcredits'] = intval($_GET['extcredits'][$i]);
echo 'result = result.replace(/pageviews/g, \'<u>' . $lang['settings_credits_formula_pageviews'] . '</u>\');'; ?> $('creditsformulaexp').innerHTML = '<u><?php echo $lang['settings_credits_formula_credits']; ?> </u>=' + result; } </script> <?php shownav('tools', 'nav_creditwizard'); showsubmenu('nav_creditwizard', array(array('creditwizard_step_menu_1', 'creditwizard&step=1', $step == 1), array('creditwizard_step_menu_2', 'creditwizard&step=2', $step == 2), array('creditwizard_step_menu_3', 'creditwizard&step=3', $step == 3), array('creditwizard_step_menu_4', 'settings&operation=ec&from=creditwizard', 0), array('ec_alipay', 'ec&operation=alipay&from=creditwizard', 0))); showtips('creditwizard_tips_formula'); showformheader('creditwizard&step=2'); showtableheader(); showtitle('settings_credits_formula'); showtablerow('', 'colspan="2"', '<div class="extcredits">' . $extcreditsbtn . '<br /><a href="###" onclick="insertunit(\'digestposts\')">' . $lang['settings_credits_formula_digestposts'] . '</a> <a href="###" onclick="insertunit(\'posts\')">' . $lang['settings_credits_formula_posts'] . '</a> <a href="###" onclick="insertunit(\'oltime\')">' . $lang['settings_credits_formula_oltime'] . '</a> <a href="###" onclick="insertunit(\'pageviews\')">' . $lang['settings_credits_formula_pageviews'] . '</a> <a href="###" onclick="insertunit(\'+\')"> + </a> <a href="###" onclick="insertunit(\'-\')"> - </a> <a href="###" onclick="insertunit(\'*\')"> * </a> <a href="###" onclick="insertunit(\'/\')"> / </a> <a href="###" onclick="insertunit(\'(\', \')\')"> ( ) </a></div><div id="creditsformulaexp" class="marginbot diffcolor2">' . $creditsformulaexp . '</div><textarea name="creditsformulanew" id="creditsformulanew" style="width: 80%" rows="3" onkeyup="formulaexp()">' . dhtmlspecialchars($creditsformula) . '</textarea>'); showsubmit('settingsubmit'); showtablefooter(); showformfooter(); } else { if (!preg_match("/^([\\+\\-\\*\\/\\.\\d\\(\\)]|((extcredits[1-8]|digestposts|posts|pageviews|oltime)([\\+\\-\\*\\/\\(\\)]|\$)+))+\$/", $creditsformulanew) || !is_null(@eval(preg_replace("/(digestposts|posts|pageviews|oltime|extcredits[1-8])/", "\$\\1", $creditsformulanew) . ';'))) { cpmsg('settings_creditsformula_invalid', '', 'error'); } $creditsformulaexpnew = $creditsformulanew; foreach (array('digestposts', 'posts', 'oltime', 'pageviews', 'extcredits1', 'extcredits2', 'extcredits3', 'extcredits4', 'extcredits5', 'extcredits6', 'extcredits7', 'extcredits8') as $var) { if ($extcredits[$creditsid = preg_replace("/^extcredits(\\d{1})\$/", "\\1", $var)]['available']) { $replacement = $extcredits[$creditsid]['title']; } else { $replacement = $lang['settings_credits_formula_' . $var]; } $creditsformulaexpnew = str_replace($var, '<u>' . $replacement . '</u>', $creditsformulaexpnew);
$var['type'] = $lang['plugins_edit_vars_type_' . $var['type']]; $var['title'] .= isset($lang[$var['title']]) ? '<br />' . $lang[$var['title']] : ''; showtablerow('', array('class="td25"', 'class="td28"'), array("<input class=\"checkbox\" type=\"checkbox\" name=\"delete[]\" value=\"{$var['pluginvarid']}\">", "<input type=\"text\" class=\"txt\" size=\"2\" name=\"displayordernew[{$var['pluginvarid']}]\" value=\"{$var['displayorder']}\">", $var['title'], $var['variable'], $var['type'], "<a href=\"" . ADMINSCRIPT . "?action=plugins&operation=vars&pluginid={$plugin['pluginid']}&pluginvarid={$var['pluginvarid']}\" class=\"act\">{$lang['detail']}</a>")); } showtablerow('', array('class="td25"', 'class="td28"'), array(cplang('add_new'), '<input type="text" class="txt" size="2" name="newdisplayorder" value="0">', '<input type="text" class="txt" size="15" name="newtitle">', '<input type="text" class="txt" size="15" name="newvariable">', '<select name="newtype"> <option value="number">' . cplang('plugins_edit_vars_type_number') . '</option> <option value="text" selected>' . cplang('plugins_edit_vars_type_text') . '</option> <option value="textarea">' . cplang('plugins_edit_vars_type_textarea') . '</option> <option value="radio">' . cplang('plugins_edit_vars_type_radio') . '</option> <option value="select">' . cplang('plugins_edit_vars_type_select') . '</option> <option value="selects">' . cplang('plugins_edit_vars_type_selects') . '</option> <option value="color">' . cplang('plugins_edit_vars_type_color') . '</option> <option value="date">' . cplang('plugins_edit_vars_type_date') . '</option> <option value="datetime">' . cplang('plugins_edit_vars_type_datetime') . '</option> <option value="forum">' . cplang('plugins_edit_vars_type_forum') . '</option> <option value="forums">' . cplang('plugins_edit_vars_type_forums') . '</option> <option value="group">' . cplang('plugins_edit_vars_type_group') . '</option> <option value="groups">' . cplang('plugins_edit_vars_type_groups') . '</option> <option value="extcredit">' . cplang('plugins_edit_vars_type_extcredit') . '</option> <option value="forum_text">' . cplang('plugins_edit_vars_type_forum_text') . '</option> <option value="forum_textarea">' . cplang('plugins_edit_vars_type_forum_textarea') . '</option> <option value="forum_radio">' . cplang('plugins_edit_vars_type_forum_radio') . '</option> <option value="forum_select">' . cplang('plugins_edit_vars_type_forum_select') . '</option> <option value="group_text">' . cplang('plugins_edit_vars_type_group_text') . '</option> <option value="group_textarea">' . cplang('plugins_edit_vars_type_group_textarea') . '</option> <option value="group_radio">' . cplang('plugins_edit_vars_type_group_radio') . '</option> <option value="group_select">' . cplang('plugins_edit_vars_type_group_select') . '</option> </seletc>', '')); showsubmit('editsubmit', 'submit', 'del'); showtablefooter(); showformfooter(); showtagfooter('div');
function showsendsms() { global $lang; global $Plang; showtablerow('', array('class="th12"', ''), array($Plang['smstong_members_sendsms_message'], '<textarea name="message" cols="100" rows="10"></textarea>')); showtablerow('', array('', 'class="td12"'), array('', '<ul><li><input type="hidden" value="sendsms" name="notifymembers" id="viapm" /><font color="red">' . $Plang['smstong_notice_count'] . '</font> <span class="diffcolor2">' . $lang['members_newsletter_num'] . ':</span><input type="text" class="txt" name="pertask" value="100" size="10" maxlength="3" onblur="if (isNaN(this.value*1)) {this.value = 100;} if (this.value*1>500) {this.value = 500;}"></li></ul>')); showtablerow('', array('class="th12"', ''), array('', '<strong>' . $Plang['smstong_members_sendsms_notice2'] . '</strong>')); }
C::t('common_setting')->update('statdisable', $newstatdisable); require_once libfile('function/cache'); updatecache('setting'); } } } elseif ($operation == 'custommenu') { if (!$do) { if (!submitcheck('optionsubmit')) { $mpp = 10; $startlimit = ($page - 1) * $mpp; $num = C::t('common_admincp_cmenu')->count_by_uid($_G['uid']); $multipage = multi($num, $mpp, $page, ADMINSCRIPT . '?action=misc&operation=custommenu'); $optionlist = $ajaxoptionlist = ''; foreach (C::t('common_admincp_cmenu')->fetch_all_by_uid($_G['uid'], $startlimit, $mpp) as $custom) { $custom['url'] = rawurldecode($custom['url']); $optionlist .= showtablerow('', array('class="td25"', 'class="td28"', '', 'class="td26"'), array("<input type=\"checkbox\" class=\"checkbox\" name=\"delete[]\" value=\"{$custom['id']}\">", "<input type=\"text\" class=\"txt\" size=\"3\" name=\"displayordernew[{$custom['id']}]\" value=\"{$custom['displayorder']}\">", "<input type=\"text\" class=\"txt\" size=\"25\" name=\"titlenew[{$custom['id']}]\" value=\"" . cplang($custom['title']) . "\"><input type=\"hidden\" name=\"langnew[{$custom['id']}]\" value=\"{$custom['title']}\">", "<input type=\"text\" class=\"txt\" size=\"40\" name=\"urlnew[{$custom['id']}]\" value=\"{$custom['url']}\">"), TRUE); $ajaxoptionlist .= '<li><a href="' . $custom['url'] . '" target="' . (substr(rawurldecode($custom['url']), 0, 17) == ADMINSCRIPT . '?action=' ? 'main' : '_blank') . '">' . cplang($custom['title']) . '</a></li>'; } echo <<<EOT <script type="text/JavaScript"> \tvar rowtypedata = [ \t\t[ \t\t\t[1,'', 'td25'], \t\t\t[1,'<input type="text" class="txt" name="newdisplayorder[]" size="3">', 'td28'], \t\t\t[1,'<input type="text" class="txt" name="newtitle[]" size="25">'], \t\t\t[1,'<input type="text" class="txt" name="newurl[]" size="40">', 'td26'] \t\t] \t]; </script> EOT; shownav('tools', 'nav_custommenu');
} else { echo '<td width="' . $rowwidth . '%" class="hover" align="center"><a href="' . ADMINSCRIPT . '?action=adv&operation=ad&type=' . $adv['class'] . '">'; echo file_exists(B_ROOT . './static/image/admin/' . $adv['class'] . '.gif') ? '<img src="static/image/admin/' . $adv['class'] . '.gif" /><br />' : ''; echo $adv['name'] . ($ads[$adv['class']] ? '(' . $ads[$adv['class']] . ')' : '') . ($adv['filemtime'] > TIMESTAMP - 86400 ? ' <font color="red">New!</font>' : ''); echo '</a></td>'; } $i--; if (!$i) { $i = $row; } } if ($i != $row) { echo str_repeat('<td></td>', $i); } } else { showtablerow('', '', $lang['adv_nonexistence']); } if ($customadv) { $img = file_exists(B_ROOT . './static/image/admin/' . $customadv['class'] . '.gif') ? '<img src="static/image/admin/' . $customadv['class'] . '.gif" /><br />' : ''; $query = DB::query("SELECT * FROM " . DB::table('advertisement_custom') . " ORDER BY id"); $i = $row; while ($custom = DB::fetch($query)) { if ($i == $row) { echo '<tr>'; } echo '<td width="' . $rowwidth . '%" class="hover" align="center"><div id="op_' . $custom['id'] . '"><a href="' . ADMINSCRIPT . '?action=adv&operation=ad&type=' . $customadv['class'] . '&customid=' . $custom['id'] . '">'; echo $img . $lang['adv_custom'] . ' ' . $custom['name'] . ($ads['custom_' . $custom['id']] ? '(' . $ads['custom_' . $custom['id']] . ')' : ''); echo '</a><br /><div class="right">'; echo '<a onclick="ajaxget(this.href, \'op_' . $custom['id'] . '\');return false;" href="' . ADMINSCRIPT . '?action=adv&operation=custom&do=edit&id=' . $custom['id'] . '">' . $lang['edit'] . '</a> '; echo '<a onclick="ajaxget(this.href, \'op_' . $custom['id'] . '\');return false;" href="' . ADMINSCRIPT . '?action=adv&operation=custom&do=delete&id=' . $custom['id'] . '">' . $lang['delete'] . '</a>'; echo '</div></div></td>';
showtablerow('', array('class="vtop td24 lineheight"', 'class="lineheight team"'), array(cplang('home_dev_thanks'), '<a href="http://www.discuz.net/home.php?mod=space&uid=122246" class="lightlink2 smallfont" target="_blank">Heyond</a> <a href="http://www.discuz.net/home.php?mod=space&uid=632268" class="lightlink2 smallfont" target="_blank">JinboWang</a> <a href="http://www.discuz.net/home.php?mod=space&uid=15104" class="lightlink2 smallfont" target="_blank">Redstone</a> <a href="http://www.discuz.net/home.php?mod=space&uid=10407" class="lightlink2 smallfont" target="_blank">Qiang Liu</a> <a href="http://www.discuz.net/home.php?mod=space&uid=210272" class="lightlink2 smallfont" target="_blank">XiaoDunFang</a> <a href="http://www.discuz.net/home.php?mod=space&uid=86282" class="lightlink2 smallfont" target="_blank">Jianxieshui</a> <a href="http://www.discuz.net/home.php?mod=space&uid=9600" class="lightlink2 smallfont" target="_blank">Theoldmemory</a> <a href="http://www.discuz.net/home.php?mod=space&uid=2629" class="lightlink2 smallfont" target="_blank">Rain5017</a> <a href="http://www.discuz.net/home.php?mod=space&uid=26926" class="lightlink2 smallfont" target="_blank">Snow Wolf</a> <a href="http://www.discuz.net/home.php?mod=space&uid=17149" class="lightlink2 smallfont" target="_blank">Hehechuan</a> <a href="http://www.discuz.net/home.php?mod=space&uid=9132" class="lightlink2 smallfont" target="_blank">Pk0909</a> <a href="http://www.discuz.net/home.php?mod=space&uid=248" class="lightlink2 smallfont" target="_blank">feixin</a> <a href="http://www.discuz.net/home.php?mod=space&uid=675" class="lightlink2 smallfont" target="_blank">Laobing Jiuba</a> <a href="http://www.discuz.net/home.php?mod=space&uid=13877" class="lightlink2 smallfont" target="_blank">Artery</a> <a href="http://www.discuz.net/home.php?mod=space&uid=233" class="lightlink2 smallfont" target="_blank">Huli Hutu</a> <a href="http://www.discuz.net/home.php?mod=space&uid=122" class="lightlink2 smallfont" target="_blank">Lao Gui</a> <a href="http://www.discuz.net/home.php?mod=space&uid=159" class="lightlink2 smallfont" target="_blank">Tyc</a> <a href="http://www.discuz.net/home.php?mod=space&uid=177" class="lightlink2 smallfont" target="_blank">Stoneage</a> <a href="http://www.discuz.net/home.php?mod=space&uid=7155" class="lightlink2 smallfont" target="_blank">Gregry</a>')); /*vot*/ showtablerow('', array('class="vtop td24 lineheight"', 'class="lineheight"'), array('English version', '<a href="http://codersclub.org/discuzx/" class="lightlink2" target="_blank">Valery Votintsev at sources.ru</a>')); showtablerow('', array('class="vtop td24 lineheight"', 'class="lineheight"'), array(cplang('home_dev_links'), '<a href="http://www.comsenz.com" class="lightlink2" target="_blank">Website</a>, <a href="http://idc.comsenz.com" class="lightlink2" target="_blank">Web Hosting</a>, <a href="http://www.comsenz.com/category-51" class="lightlink2" target="_blank">Purchase</a>, <a href="http://www.discuz.com/" class="lightlink2" target="_blank">Discuz! Products</a>, <a href="http://www.comsenz.com/downloads/styles/discuz" class="lightlink2" target="_blank">Templates</a>, <a href="http://www.comsenz.com/downloads/plugins/discuz" class="lightlink2" target="_blank">Plugins</a>, <a href="http://faq.comsenz.com" class="lightlink2" target="_blank">Documentation</a>, <a href="http://www.discuz.net/" class="lightlink2" target="_blank">Forum</a>')); showtablefooter(); echo '</div>';
} showsetting($langs['slide_img'] . $j, 'pic' . $j, $pic, 'filetext', '', 0, $grouplogohtml); showsetting($langs['bird_slide_link'] . $j, 'movie' . $j, $result['movie' . $j], 'text'); } showsubmit('submit'); showtablefooter(); showformfooter(); return; } $type = intval($_G['sr_type']); !in_array($type, array(1, 2)) && ($type = 1); $result = DB::fetch_first("SELECT * FROM " . DB::table('sanree_brand_slide') . ' where id=' . $type); showsubmenu($menustr); showtableheader('', 'nobottom'); $typeclass = array(1, 2); showtablerow('', array(), array(shownavmenu($type, $typeclass, $langs))); showtablefooter(); showformheader($thisurl . '&type=' . $type, 'enctype'); showtableheader($langs['slide'], 'nobottom'); for ($j = 1; $j < 6; $j++) { $grouplogohtml = ''; $pic = ''; if ($result['pic' . $j]) { $pic = $result['pic' . $j]; $grouplogohtml = '<label>' . $langs['slideimgtip'] . '<br /><img src="' . fiximage($pic) . '?' . random(6) . '" width="400" height="100" />'; } showsetting($langs['slide_img'] . $j, 'pic' . $j, $pic, 'filetext', '', 0, $grouplogohtml); showsetting($langs['slide_link'] . $j, 'movie' . $j, $result['movie' . $j], 'text'); } showsubmit('submit'); showtablefooter();
} foreach ($fups as $fid => $num) { C::t('forum_forumfield')->update_groupnum($fid, $updateforum . $num); } cpmsg('group_mod_succeed', 'action=group&operation=mod', 'succeed'); } loadcache('grouptype'); $perpage = 50; $page = intval($_GET['page']) ? intval($_GET['page']) : 1; $startlimit = ($page - 1) * $perpage; $count = C::t('forum_forum')->validate_level_num(); $multipage = multi($count, $perpage, $page, ADMINSCRIPT . "?action=group&operation=mod&submit=yes"); $query = C::t('forum_forum')->fetch_all_validate($startlimit, $startlimit + $perpage); foreach ($query as $group) { $groups .= showtablerow('', array('class="td25"', '', ''), array("<input type=\"checkbox\" name=\"fidarray[]\" value=\"{$group['fid']}\" class=\"checkbox\">", "<a href=\"forum.php?mod=forumdisplay&fid={$group['fid']}\" target=\"_blank\">{$group['name']}</a>", empty($_G['cache']['grouptype']['first'][$group[fup]]) ? $_G['cache']['grouptype']['second'][$group[fup]]['name'] : $_G['cache']['grouptype']['first'][$group[fup]]['name'], "<a href=\"home.php?mod=space&uid={$group['founderuid']}\" target=\"_blank\">{$group['foundername']}</a>", dgmdate($group['dateline'])), TRUE); $groups .= showtablerow('', array('', 'colspan="4"'), array('', cplang('group_mod_description') . ' : ' . $group['description']), TRUE); } shownav('group', 'nav_group_mod'); showsubmenu('nav_group_mod'); showformheader("group&operation=mod"); showtableheader('group_mod_wait'); showsubtitle(array('', 'groups_manage_name', 'groups_editgroup_category', 'groups_manage_founder', 'groups_manage_createtime')); echo $groups; showsubmit('', '', '', '<input type="checkbox" name="chkall" id="chkall" class="checkbox" onclick="checkAll(\'prefix\', this.form, \'fidarray\')" /><label for="chkall">' . cplang('select_all') . '</label> <input type="submit" class="btn" name="validate" value="' . cplang('validate') . '" /> <input type="submit" class="btn" name="delsubmit" value="' . cplang('delete') . '" onclick="return confirm(\'' . cplang('group_mod_delconfirm') . '\')" />', $multipage); showtablefooter(); showformfooter(); } function showgroup(&$forum, $type = '', $last = '') { global $_G; loadcache('grouptype');
require_once libfile('function/cache'); writetocache('dzapp_haodai_setting', getcachevars(array('hd_token' => $new_hd_token))); showtablerow('', array('class="td24"'), array($lang['callback_status'], '<font color="green">' . $lang['valid'] . '</font>')); } else { $auth_url = $client->oauth->getAuthorizeURL(HD_CALLBACK_URL); showtablerow('', array('class="td24"'), array($lang['callback_status'], '<font color="red">' . $lang['callback_expired'] . '</font> <a href="' . $auth_url . '"><img src="source/plugin/dzapp_haodai/images/haodai_login.png" class="vmiddle"></a>')); } } else { showtablerow('', array('class="td24"'), array($lang['callback_status'], '<font color="green">' . $lang['valid'] . '</font>')); } } elseif (isset($hd_token['expires']) && TIMESTAMP < $hd_token['expires'] - 3600) { showtablerow('', array('class="td24"'), array($lang['callback_status'], '<font color="green">' . $lang['valid'] . '</font>')); } else { $oauth = new HaoDaiOAuth(HD_AKEY, HD_SKEY); $auth_url = $oauth->getAuthorizeURL(HD_CALLBACK_URL); showtablerow('', array('class="td24"'), array($lang['callback_status'], '<font color="red">' . $lang['callback_expired'] . '</font> <a href="' . $auth_url . '"><img src="source/plugin/dzapp_haodai/images/haodai_login.png" class="vmiddle"></a>')); } } showtablefooter(); } elseif ($_GET['want'] == 'import') { if (!submitcheck('ok')) { showformheader('plugins&operation=config&identifier=dzapp_haodai&pmod=admincp_callback&want=import'); showtableheader('import_callback'); showsetting($lang['appkey'], 'AKEY', defined('HD_AKEY') ? HD_AKEY : '', 'text'); showsetting($lang['appsecret'], 'SKEY', defined('HD_SKEY') ? HD_SKEY : '', 'text'); showsetting($lang['ref'], 'REF', defined('HD_REF') ? HD_REF : '', 'text'); showsetting($lang['callback_url'], 'CALLBACK_URL', defined('HD_CALLBACK_URL') ? HD_CALLBACK_URL : $_G['siteurl'] . 'plugin.php?id=dzapp_haodai:callback', 'text'); showsetting($lang['host_url'], 'API_HOST', defined('HD_API_HOST') ? HD_API_HOST : 'http://api.haodai.com/', 'text'); showsubmit('ok', "ok"); showtablefooter(); showformfooter();
<?php !defined('IN_ADMINCP') && exit('Access Denied'); if (file_exists(DISCUZ_ROOT . './data/plugindata/dsu_kksfs_dzx.lang.php')) { include DISCUZ_ROOT . './data/plugindata/dsu_kksfs_dzx.lang.php'; $kk_lang = $scriptlang['dsu_kksfs_dzx']; } else { loadcache('pluginlanguage_script'); $kk_lang = $_G['cache']['pluginlanguage_script']['dsu_kksfs_dzx']; } if (submitcheck('clean', true)) { DB::query('TRUNCATE TABLE ' . DB::table('dsu_sfs_log')); cpmsg($kk_lang['clean_succeed'], 'action=plugins&operation=config&identifier=dsu_kksfs_dzx&pmod=logs', 'succeed'); } showtableheader(''); showsubtitle(explode('|', $kk_lang['table_title'])); $page = $_G['gp_page'] ? intval($_G['gp_page']) : 1; $start = ($page - 1) * 20; $query = DB::query('SELECT * FROM ' . DB::table('dsu_sfs_log') . " ORDER BY timestamp DESC LIMIT {$start},20"); while ($row = DB::fetch($query)) { $row['uid'] = $row['uid'] ? $row['uid'] : $kk_lang['no_uid']; if ($row['reason'] == '-1') { $row['reason'] = $kk_lang['reason_-1']; } elseif ($row['reason'] == '1') { $row['reason'] = $kk_lang['reason_1']; } showtablerow('', '', array($row['uid'], $row['reason'], $row['rate'], dgmdate($row['timestamp'], 'u'))); } showtablefooter(); $amount = DB::result_first('SELECT COUNT(*) FROM ' . DB::table('dsu_sfs_log')); echo '<a href="admin.php?action=plugins&operation=config&identifier=dsu_kksfs_dzx&pmod=logs&clean=' . FORMHASH . '">' . $kk_lang['clean'] . '</a>' . multi($amount, 20, $page, 'admin.php?action=plugins&operation=config&identifier=dsu_kksfs_dzx&pmod=logs', 0, 20, 1, 1);
$tablestatus = gettablestatus($tablename); $postcount = $tablestatus['Rows']; $data_length = $tablestatus['Data_length']; $index_length = $tablestatus['Index_length']; $opstr = '<a href="' . ADMINSCRIPT . '?action=postsplit&operation=split&tableid=0">' . cplang('postsplit_name') . '</a>'; showtablerow('', array('', '', '', 'class="td25"'), array($tablename, $data_length, "<input type=\"text\" class=\"txt\" name=\"memo[0]\" value=\"{$posttable_info[0]['memo']}\" />", $opstr)); $query = DB::query("SHOW TABLES LIKE '" . DB::table('forum_post') . "\\_%'"); while ($table = DB::fetch($query)) { list($tempkey, $tablename) = each($table); $tableid = gettableid($tablename); if (!preg_match('/^\\d+$/', $tableid)) { continue; } $tablestatus = gettablestatus($tablename); $opstr = '<a href="' . ADMINSCRIPT . '?action=postsplit&operation=split&tableid=' . $tableid . '">' . cplang('postsplit_name') . '</a>'; showtablerow('', array('', '', '', 'class="td25"'), array($tablename, $tablestatus['Data_length'], "<input type=\"text\" class=\"txt\" name=\"memo[{$tableid}]\" value=\"{$posttable_info[$tableid]['memo']}\" />", $opstr)); } showsubmit('postsplit_manage', 'postsplit_manage_update_memo_submit'); showtablefooter(); showformfooter(); } else { $posttable_info = array(); foreach ($_G['gp_memo'] as $key => $value) { $key = intval($key); $posttable_info[$key]['memo'] = $value; } DB::insert('common_setting', array('skey' => 'posttable_info', 'svalue' => daddslashes(serialize($posttable_info))), false, true); save_syscache('posttable_info', $posttable_info); update_posttableids(); updatecache('setting'); cpmsg('postsplit_table_memo_update_succeed', 'action=postsplit&operation=manage', 'succeed');
cpmsg('setting_update_succeed', 'action=domain&operation=app', 'succeed'); } } elseif ($operation == 'root') { $roottype = array('home' => $lang['domain_home'], 'group' => $navs[3]['navname'], 'forum' => $lang['domain_forum'], 'topic' => $lang['domain_topic'], 'channel' => $lang['channel']); if (!submitcheck('submit')) { showtips('setting_domain_root_tips'); showformheader('domain&operation=root'); showtableheader(); showsubtitle(array('name', 'setting_domain_app_domain')); $hiddenarr = array(); foreach ($roottype as $type => $desc) { if (in_array($type, array('topic', 'channel')) && !helper_access::check_module('portal') || $type == 'home' && !$_G['setting']['homepagestyle'] || $type == 'group' && !helper_access::check_module('group')) { $hiddenarr["domainnew[{$type}]"] = ''; } else { $domainroot = $_G['setting']['domain']['root'][$type]; showtablerow('', array('class="td25"', ''), array($desc, "<input type=\"text\" class=\"txt\" style=\"width:50%;\" name=\"domainnew[{$type}]\" value=\"{$domainroot}\">")); } } showsubmit('submit'); showtablefooter(); showhiddenfields($hiddenarr); showformfooter(); } else { $oldroot = $_G['setting']['domain']['root']; $_G['setting']['domain']['root'] = array(); foreach ($_GET['domainnew'] as $idtype => $domain) { if (preg_match('/^((http|https|ftp):\\/\\/|\\.)|(\\/|\\.)$/i', $domain)) { cpmsg('setting_domain_http_error', '', 'error'); } if ($_G['setting']['domain']['root'][$idtype] != $domain) { $updatetype = $idtype == 'forum' ? array('forum', 'channel') : $idtype;
$sql .= $hot1 ? " AND s.hot >= '{$hot1}'" : ''; $sql .= $hot2 ? " AND s.hot <= '{$hot2}'" : ''; if ($_G['adminid'] == 2 && $endtime - $starttime > 86400 * 16 || $_G['adminid'] == 3 && $endtime - $starttime > 86400 * 8) { $error = 'share_mod_range_illegal'; } if (!$error) { if ($detail) { $_G['gp_perpage'] = intval($_G['gp_perpage']) < 1 ? 20 : intval($_G['gp_perpage']); $perpage = $_G['gp_pp'] ? $_G['gp_pp'] : $_G['gp_perpage']; $query = DB::query("SELECT * FROM " . DB::table('home_share') . " s WHERE 1 {$sql} ORDER BY s.dateline DESC LIMIT " . ($page - 1) * $perpage . ",{$perpage}"); $shares = ''; require_once libfile('function/share'); while ($share = DB::fetch($query)) { $share['dateline'] = dgmdate($share['dateline']); $share = mkshare($share); $shares .= showtablerow('', '', array("<input class=\"checkbox\" type=\"checkbox\" name=\"delete[]\" value=\"{$share['sid']}\" />", "<a href=\"home.php?mod=space&uid={$share['uid']}\" target=\"_blank\">" . $share['username'] . "</a>", $share['title_template'], $share['body_template'], $share['type'], $share['dateline']), TRUE); } $sharecount = DB::result_first("SELECT count(*) FROM " . DB::table('home_share') . " s WHERE 1 {$sql}"); $multi = multi($sharecount, $perpage, $page, ADMINSCRIPT . "?action=share"); $multi = preg_replace("/href=\"" . ADMINSCRIPT . "\\?action=share&page=(\\d+)\"/", "href=\"javascript:page(\\1)\"", $multi); $multi = str_replace("window.location='" . ADMINSCRIPT . "?action=share&page='+this.value", "page(this.value)", $multi); } else { $sharecount = 0; $query = DB::query("SELECT s.sid FROM " . DB::table('home_share') . " s WHERE 1 {$sql}"); while ($share = DB::fetch($query)) { $sids .= ',' . $share['sid']; $sharecount++; } $multi = ''; } if (!$sharecount) {
while ($attachment = $db->fetch_array($query)) { if (!$attachment['remote']) { $matched = file_exists($attachdir . '/' . $attachment['attachment']) ? '' : lang('attach_lost'); $attachment['url'] = $attachurl; } else { @set_time_limit(0); if (@fclose(@fopen($ftp['attachurl'] . '/' . $attachment['attachment'], 'r'))) { $matched = ''; } else { $matched = lang('attach_lost'); } $attachment['url'] = $ftp['attachurl']; } $attachsize = sizecount($attachment['filesize']); if (!$nomatched || $nomatched && $matched) { $attachments .= showtablerow('', array('class="td25"', 'title="' . $attachment['description'] . '" class="td21"'), array("<input class=\"checkbox\" type=\"checkbox\" name=\"delete[]\" value=\"{$attachment['aid']}\" />", $attachment['remote'] ? "<span class=\"diffcolor3\">{$attachment['filename']}" : $attachment['filename'], "<a href=\"{$attachment['url']}/{$attachment['attachment']}\" class=\"smalltxt\" target=\"_blank\">" . cutstr($attachment['attachment'], 30) . "</a>", $attachment['author'], "<a href=\"viewthread.php?tid={$attachment['tid']}\" target=\"_blank\">" . cutstr($attachment['subject'], 20) . "</a>", $attachsize, $attachment['downloads'], $matched ? "<em class=\"error\">{$matched}<em>" : "<a href=\"attachment.php?aid=" . aidencode($attachment['aid']) . "&noupdate=yes\" target=\"_blank\" class=\"act nomargin\">{$lang['download']}</a>"), TRUE); } } $attachmentcount = $db->result_first("SELECT count(*) FROM {$tablepre}attachments a LEFT JOIN {$tablepre}attachmentfields af ON a.aid=af.aid, {$tablepre}posts p, {$tablepre}threads t, {$tablepre}forums f\r\n\t\t\tWHERE t.tid=a.tid AND f.fid=p.fid AND t.displayorder>='0' AND p.invisible='0' AND {$sql}"); $multipage = multi($attachmentcount, $ppp, $page, "{$BASESCRIPT}?action=attachments"); $multipage = preg_replace("/href=\"{$BASESCRIPT}\\?action=attachments&page=(\\d+)\"/", "href=\"javascript:page(\\1)\"", $multipage); $multipage = str_replace("window.location={$BASESCRIPT}.'?action=attachments&page='+this.value", "page(this.value)", $multipage); echo <<<EOT <script type="text/JavaScript"> \tfunction page(number) { \t\t\$('attachmentforum').page.value=number; \t\t\$('attachmentforum').searchsubmit.click(); \t} </script> EOT; showtagheader('div', 'admin', $searchsubmit);
$wechat_client = new WeChatClient($_G['wechat']['setting']['wechat_appId'], $_G['wechat']['setting']['wechat_appsecret']); if (in_array('plugin', $_G['setting']['rewritestatus'])) { $url = $_G['siteurl'] . rewriteoutput('plugin', 1, 'wechat', 'access', '', 'op=access'); } else { $url = $_G['siteurl'] . 'plugin.php?id=wechat:access'; } showtips(lang('plugin/wechat', 'menu_tips', array('url' => $url))); showformheader('plugins&operation=config&do=' . $pluginid . '&identifier=wechat&pmod=menu_setting'); showtableheader(); echo '<tr class="header"><th class="td25"></th><th>' . $lang['display_order'] . '</th><th style="width:350px">' . lang('plugin/wechat', 'wsq_menu_name') . '</th><th>' . lang('plugin/wechat', 'wsq_menu_keyurl') . '</th></tr>'; foreach ($setting['button'] as $k => $button) { $disabled = !empty($button['sub_button']) ? 'disabled' : ''; showtablerow('', array('', 'class="td23 td28"', '', 'class="td29"'), array("<input class=\"checkbox\" type=\"checkbox\" name=\"button[{$k}][delete]\" value=\"yes\" {$disabled}>", "<input type=\"text\" class=\"txt\" size=\"3\" name=\"button[{$k}][displayorder]\" value=\"{$button['displayorder']}\">", "<div class=\"parentnode\"><input type=\"text\" class=\"txt\" size=\"30\" name=\"button[{$k}][name]\" value=\"" . dhtmlspecialchars($button['name']) . "\"></div>", "<input type=\"text\" class=\"txt\" size=\"30\" name=\"button[{$k}][keyurl]\" value=\"" . dhtmlspecialchars($button['keyurl']) . "\">")); if (!empty($button['sub_button'])) { foreach ($button['sub_button'] as $sk => $sub_button) { showtablerow('', array('', 'class="td23 td28"', '', 'class="td29"'), array("<input class=\"checkbox\" type=\"checkbox\" name=\"button[{$k}][sub_button][{$sk}][delete]\" value=\"yes\">", "<input type=\"text\" class=\"txt\" size=\"3\" name=\"button[{$k}][sub_button][{$sk}][displayorder]\" value=\"{$sub_button['displayorder']}\">", "<div class=\"node\"><input type=\"text\" class=\"txt\" size=\"30\" name=\"button[{$k}][sub_button][{$sk}][name]\" value=\"" . dhtmlspecialchars($sub_button['name']) . "\"></div>", "<input type=\"text\" class=\"txt\" size=\"30\" name=\"button[{$k}][sub_button][{$sk}][keyurl]\" value=\"" . dhtmlspecialchars($sub_button['keyurl']) . "\">")); } } echo '<tr><td></td><td></td><td colspan="2"><div class="lastnode"><a href="###" onclick="addrow(this, 1, ' . $k . ')" class="addtr">' . lang('plugin/wechat', 'wsq_menu_sub_button') . '</a></div></td></tr>'; } echo '<tr><td></td><td class="td23 td28"></td><td colspan="2"><div><a href="###" onclick="addrow(this, 0, 0)" class="addtr">' . lang('plugin/wechat', 'wsq_menu_button') . '</a></div></td></tr>'; echo <<<EOT <script type="text/JavaScript"> var rowtypedata = [ [[1,''], [1,'<input name="newbutton[displayorder][]" value="" size="3" type="text" class="txt">', 'td23 td28'], [1, '<input name="newbutton[name][]" value="" size="30" type="text" class="txt">'], [1, '<input name="newbutton[keyurl][]" value="" size="30" type="text" class="txt">', 'td29']], [[1,''], [1,'<input name="newsub_button[{1}][displayorder][]" value="" size="3" type="text" class="txt">', 'td23 td28'], [1, '<div class=\\"node\\"><input name="newsub_button[{1}][name][]" value="" size="30" type="text" class="txt"></div>'], [1, '<input name="newsub_button[{1}][keyurl][]" value="" size="30" type="text" class="txt">', 'td29']], ]; </script> EOT; showsubmit('menusubmit', lang('plugin/wechat', 'wsq_menu_save'), 'del', '<input type="submit" class="btn" name="pubsubmit" value="' . lang('plugin/wechat', 'wsq_menu_pub') . '" />'); showtablefooter();
showtablerow('', array('', 'class="td23 td28"', '', 'class="td29"'), array("", "<i>" . lang('plugin/wechat', 'scan') . "</i>", "<textarea class=\"tarea\" name=\"response[scan]\" id=\"res_scan\" rows=\"5\" cols=\"40\">" . dhtmlspecialchars($response['scan']) . "</textarea>" . "<br /><a href=\"javascript:;\" id=\"rsel\" onclick=\"showResource('res_scan')\">" . lang('plugin/wechat', 'resource_select') . "</a>")); if ($responsehook['receiveMsg::text']['plugin'] == 'wechat' && $responsehook['receiveMsg::text']['class'] == 'WSQResponse' && $responsehook['receiveMsg::text']['method'] == 'text') { showtablerow('class="header"', array('', 'class="td23 td28"', '', 'class="td29"'), array("", lang('plugin/wechat', 'response_message'), "<p class=\"mbn\">" . lang('plugin/wechat', 'response_custom') . " " . ($response['textback'] ? "<a class=\"normal\" href=\"" . ADMINSCRIPT . "?action=plugins&operation=config&do={$pluginid}&identifier=wechat&pmod=response_setting&text=restore\">[" . lang('plugin/wechat', 'response_switch_plugin_mode', array('plugin' => $response['textback']['plugin'])) . "]</a></p>" : ''))); foreach ($response['text'] as $k => $text) { showtablerow('', array('', 'class="td23 td28"', 'class="td29"'), array("<input class=\"checkbox\" type=\"checkbox\" name=\"response[text][{$k}][delete]\" value=\"yes\">", "<div class=\"parentnode\"><input type=\"text\" class=\"txt\" size=\"30\" name=\"response[text][{$k}][keyword]\" value=\"" . dhtmlspecialchars($text['keyword']) . "\"></div>", "<textarea class=\"tarea\" name=\"response[text][{$k}][response]\" rows=\"5\" id=\"res_text_{$k}\" cols=\"40\">" . dhtmlspecialchars($text['response']) . "</textarea>" . "<br /><a href=\"javascript:;\" id=\"rsel\" onclick=\"showResource('res_text_{$k}')\">" . lang('plugin/wechat', 'resource_select') . "</a>")); } echo '<tr><td></td><td class="td23 td28"></td><td colspan="2"><div><a href="###" onclick="addrow(this, 0, 0)" class="addtr">' . lang('plugin/wechat', 'response_add_message') . '</a></div></td></tr>'; echo <<<EOT <script type="text/JavaScript"> var rowtypedata = [ [[1,''], [1, '<input name="newresponse[keyword][]" value="" size="30" type="text" class="txt">'], [1, '<textarea class="tarea" name="newresponse[response][]" rows="5" cols="40"></textarea>', 'td29']], ]; </script> EOT; } else { showtablerow('class="header"', array('', 'class="td23 td28"', '', 'class="td29"'), array("", lang('plugin/wechat', 'response_message'), "<p>" . lang('plugin/wechat', 'response_plugin_mode', array('plugin' => $responsehook['receiveMsg::text']['plugin'])) . " <a class=\"normal\" href=\"" . ADMINSCRIPT . "?action=plugins&operation=config&do={$pluginid}&identifier=wechat&pmod=response_setting&text=custom\">[" . lang('plugin/wechat', 'response_switch_custom_mode') . "]</a></p>")); } showsubmit('menusubmit', 'submit', 'del'); showtablefooter(); showformfooter(); } else { if (!empty($_GET['newresponse'])) { foreach ($_GET['newresponse']['keyword'] as $k => $keyword) { $item = array('keyword' => $keyword, 'response' => $_GET['newresponse']['response'][$k]); $response['text'][] = $item; } } foreach ($_GET['response']['text'] as $k => $value) { if ($value['delete']) { unset($response['text'][$k]); continue;
$post = C::t('forum_post')->fetch_threadpost_by_tid_invisible($thread['tid']); $thread = array_merge($thread, $post); $thread['message'] = discuzcode($thread['message'], $thread['smileyoff'], $thread['bbcodeoff'], sprintf('%00b', $thread['htmlon']), $thread['allowsmilies'], $thread['allowbbcode'], $thread['allowimgcode'], $thread['allowhtml']); $thread['moddateline'] = dgmdate($thread['moddateline']); $thread['dateline'] = dgmdate($thread['dateline']); if ($thread['attachment']) { require_once libfile('function/attachment'); foreach (C::t('forum_attachment_n')->fetch_all_by_id('tid:' . $thread['tid'], 'tid', $thread['tid']) as $attach) { $_G['setting']['attachurl'] = $attach['remote'] ? $_G['setting']['ftp']['attachurl'] : $_G['setting']['attachurl']; $attach['url'] = $attach['isimage'] ? " {$attach['filename']} (" . sizecount($attach['filesize']) . ")<br /><br /><img src=\"" . $_G['setting']['attachurl'] . "forum/{$attach['attachment']}\" onload=\"if(this.width > 100) {this.resized=true; this.width=100;}\">" : "<a href=\"" . $_G['setting']['attachurl'] . "forum/{$attach['attachment']}\" target=\"_blank\">{$attach['filename']}</a> (" . sizecount($attach['filesize']) . ")"; $thread['message'] .= "<br /><br />{$lang['attachment']}: " . attachtype(fileext($attach['filename']) . "\t") . $attach['url']; } } showtablerow("id=\"mod_{$thread['tid']}_row1\"", array('rowspan="3" class="rowform threadopt" style="width:80px;"', 'class="threadtitle"'), array("<ul class=\"nofloat\"><li><input class=\"radio\" type=\"radio\" name=\"moderate[{$thread['tid']}]\" id=\"mod_{$thread['tid']}_1\" value=\"delete\" " . (empty($disabledstr) ? "checked=\"checked\"" : '') . " {$disabledstr} /><label for=\"mod_{$thread['tid']}_1\">{$lang['delete']}</label></li><li><input class=\"radio\" type=\"radio\" name=\"moderate[{$thread['tid']}]\" id=\"mod_{$thread['tid']}_2\" value=\"undelete\" {$disabledstr}/><label for=\"mod_{$thread['tid']}_2\">{$lang['undelete']}</label></li><li><input class=\"radio\" type=\"radio\" name=\"moderate[{$thread['tid']}]\" id=\"mod_{$thread['tid']}_3\" value=\"ignore\" {$disabledstr}/><label for=\"mod_{$thread['tid']}_3\">{$lang['ignore']}</label></li></ul>", "<h3><a href=\"forum.php?mod=forumdisplay&fid={$thread['fid']}\" target=\"_blank\">{$thread['forumname']}</a> » {$thread['subject']}</h3><p><span class=\"bold\">{$lang['author']}:</span> <a href=\"home.php?mod=space&uid={$thread['authorid']}\" target=\"_blank\">{$thread['author']}</a> <span class=\"bold\">{$lang['time']}:</span> {$thread['dateline']} {$lang['threads_replies']}: {$thread['replies']} {$lang['threads_views']}: {$thread['views']}</p>")); showtablerow("id=\"mod_{$thread['tid']}_row2\"", 'colspan="2" style="padding: 10px; line-height: 180%;"', '<div style="overflow: auto; overflow-x: hidden; max-height:120px; height:auto !important; height:120px; word-break: break-all;">' . $thread['message'] . '</div>'); showtablerow("id=\"mod_{$thread['tid']}_row3\"", 'class="threadopt threadtitle" colspan="2"', "{$lang['operator']}: <a href=\"home.php?mod=space&uid={$thread['moduid']}\" target=\"_blank\">{$thread['modusername']}</a> {$lang['recyclebin_delete_time']}: {$thread['moddateline']} {$lang['reason']}: {$thread['reason']}"); } } showsubmit('rbsubmit', 'submit', '', '<a href="#rb" onclick="checkAll(\'option\', $(\'rbform\'), \'delete\')">' . cplang('recyclebin_all_delete') . '</a> <a href="#rb" onclick="checkAll(\'option\', $(\'rbform\'), \'undelete\')">' . cplang('recyclebin_all_undelete') . '</a> <a href="#rb" onclick="checkAll(\'option\', $(\'rbform\'), \'ignore\')">' . cplang('recyclebin_all_ignore') . '</a> ', $multi); showtablefooter(); showformfooter(); echo '<iframe name="rbframe" style="display:none"></iframe>'; showtagfooter('div'); } } else { $moderate = $_GET['moderate']; $moderation = array('delete' => array(), 'undelete' => array(), 'ignore' => array()); if (is_array($moderate)) { foreach ($moderate as $tid => $action) { $moderation[$action][] = intval($tid); }
DB::query("DELETE FROM " . DB::table('common_taskvar') . " WHERE taskid='{$id}'"); DB::query("DELETE FROM " . DB::table('common_mytask') . " WHERE taskid='{$id}'"); cpmsg('tasks_del', 'action=tasks', 'succeed'); } elseif ($operation == 'type') { shownav('extended', 'nav_tasks'); showsubmenu('nav_tasks', array(array('admin', 'tasks', 0), $submenus ? array(array('menu' => 'add', 'submenu' => $submenus), '', 0) : array(), array('nav_task_type', 'tasks&operation=type', 1))); showtips('tasks_tips_add_type'); $tasks = gettasks(); showtableheader('', 'fixpadding'); if ($tasks) { showsubtitle(array('name', 'tasks_version', 'copyright', '')); foreach ($tasks as $task) { showtablerow('', '', array($task['name'] . ($task['filemtime'] > TIMESTAMP - 86400 ? ' <font color="red">New!</font>' : ''), $task['version'], $task['copyright'], in_array($task['class'], $custom_scripts) ? "<a href=\"" . ADMINSCRIPT . "?action=tasks&operation=upgrade&script={$task['class']}\" class=\"act\">{$lang['tasks_upgrade']}</a> <a href=\"" . ADMINSCRIPT . "?action=tasks&operation=uninstall&script={$task['class']}\" class=\"act\">{$lang['tasks_uninstall']}</a><br />" : "<a href=\"" . ADMINSCRIPT . "?action=tasks&operation=install&script={$task['class']}\" class=\"act\">{$lang['tasks_install']}</a>")); } } else { showtablerow('', '', $lang['task_module_nonexistence']); } showtablefooter(); } elseif ($operation == 'install' && $_G['gp_script']) { if (DB::result_first("SELECT COUNT(*) FROM " . DB::table('common_task') . " WHERE scriptname='{$_G['gp_script']}'")) { cpmsg('tasks_install_duplicate', '', 'error'); } require_once libfile('task/' . $_G['gp_script'], 'class'); $taskclass = 'task_' . $_G['gp_script']; $task = new $taskclass(); if (method_exists($task, 'install')) { $task->install(); } $custom_types[$_G['gp_script']] = array('name' => lang('task/' . $_G['gp_script'], $task->name), 'version' => $task->version); DB::query("REPLACE INTO " . DB::table('common_setting') . " (skey, svalue) VALUES ('tasktypes', '" . addslashes(serialize($custom_types)) . "')"); cpmsg('tasks_installed', 'action=tasks&operation=type', 'succeed');