<?php define('WAP_MODE', 1); include dirname(dirname(__FILE__)) . '/include/general.inc.php'; include 'wap.fun.php'; parse_str(un_virtual($_SERVER['QUERY_STRING']), $temparr); //处理子站id $nsid = empty($temparr['sid']) ? 0 : max(0, intval($temparr['sid'])); if ($nsid && empty($subsites[$nsid])) { $nsid = 0; } switch_cache($nsid); $sid = $nsid; if_siteclosed($sid); if (!$action) { wap_header(wap_lang('wap_login'), '', 0); $memberid && message('wap_login_re_ok', 'back'); echo wap_lang('wap_username') . '<br/><input name="username" size="15" emptyok="false"/><br/>' . wap_lang('wap_password') . '<br/><input name="password" size="15" emptyok="false"/><br/>' . '<br/><a href="?action=submit' . $wap_string . '&username=$(username)&password=$(password)&forward=' . M_REFERER . '">' . wap_lang('wap_justlogin') . '</a><br/>' . $link; wap_footer(); } elseif ($action == 'submit') { wap_header(wap_lang('wap_login'), '', 0); if (!$username || !$password) { message('wap_empty_input', 'back'); } include M_ROOT . 'include/admin.fun.php'; strlen($username = trim($username)) < 3 && message('wap_member_name_fail', 'back'); if (!$password || $password != addslashes($password)) { message('wap_password_fail', 'back'); } $guestexp = '\\xA1\\xA1|^Guest|^\\xD3\\xCE\\xBF\\xCD|\\xB9\\x43\\xAB\\xC8'; preg_match("/^\\s*\$|^c:\\con\\con\$|[%,\\*\"\\s\t\\<\\>\\&]|{$guestexp}/is", $username) && message('wap_member_name_fail', 'back');
<?php include_once dirname(dirname(__FILE__)) . '/include/general.inc.php'; include_once M_ROOT . './include/common.fun.php'; include_once M_ROOT . './include/parse.fun.php'; $cmsclosed && message(empty($cmsclosedreason) ? lang('defaultclosedreason') : mnl2br($cmsclosedreason)); $mspacedisabled && message(lang('mspacedisabled')); parse_str(un_virtual($_SERVER['QUERY_STRING'])); $mid = empty($mid) ? 0 : max(0, intval($mid)); $mcaid = empty($mcaid) ? 0 : max(0, intval($mcaid)); $ucid = empty($ucid) ? 0 : max(0, intval($ucid)); $page = empty($page) ? 1 : max(1, intval($page)); $addno = empty($addno) ? 0 : 1; include_once M_ROOT . './include/mparse.fun.php'; $temparr = array('mid' => $mid, 'mcaid' => $mcaid, 'ucid' => $ucid); $cnstr = ($mcaid ? "mcaid={$mcaid}" : '') . ($ucid ? "&ucid={$ucid}" : ''); if ($cachemscircle && (!$mslistcachenum || $page <= $mslistcachenum)) { $cachefile = htmlcac_dir('ms', 'm' . $mid % 100, 1) . cac_namepre($mid, $cnstr) . '_' . $page . '.php'; if (is_file($cachefile) && filemtime($cachefile) > $timestamp - $cachemscircle * 60) { mexit(read_htmlcac($cachefile)); } } $_da = array_merge($_da, mcn_parse($temparr)); $tplname = mcn_tpl($temparr, $addno); if (!$tplname) { message('definereltem'); } $_mp = array(); $_mp['durlpre'] = $_da['indexurl' . ($addno ? $addno : '')] . '&page={$page}'; $_mp['static'] = 0; $_mp['nowpage'] = max(1, intval($page));