<?php require "www2-funcs.php"; login_init(); bbs_session_modify_user_mode(BBS_MODE_EDITUFILE); toolbox_header("签名档修改"); assert_login(); $filename = bbs_sethomefile($currentuser["userid"], "signatures"); if (isset($_POST['text'])) { $fp = @fopen($filename, "w+"); if ($fp !== false) { fwrite($fp, str_replace("\r\n", "\n", $_POST["text"])); fclose($fp); bbs_recalc_sig(); html_success_quit($currentuser["userid"] . "签名档修改成功"); } html_error_quit("系统错误"); } ?> <form method="post" action="bbssig.php" class="large"> <fieldset><legend>修改签名档 (每 6 行为一个单位,可设置多个签名档)</legend> <textarea name="text" onkeydown='return textarea_okd(this, event);' wrap="physical" id="sfocus"> <?php echo @htmlspecialchars(file_get_contents($filename)); ?> </textarea> </fieldset> <div class="oper"> <input type="submit" value="存盘" /> <input type="reset" value="复原" /> </div> </form>
] 生命力: [<?php echo bbs_compute_user_value($lookupuser["userid"]); ?> ] 身份: [<?php echo bbs_user_level_char($lookupuser["userid"]); ?> ]。 <?php if ($usermodestr != "" && $usermodestr[1] != "") { echo substr($usermodestr, 1); } ?> </pre> <br/><span class="c36"> <?php $plansfile = bbs_sethomefile($lookupuser["userid"], "plans"); if (file_exists($plansfile)) { ?> 个人说明档如下: </span><br/> <?php $s = bbs2_readfile($plansfile); if (is_string($s)) { ?> <link rel="stylesheet" type="text/css" href="static/www2-ansi.css"/> <script type="text/javascript" src="static/www2-addons.js"></script> <div id="divPlan" class="AnsiArticleBW"><div id="dp1"> <script type="text/javascript"><!-- triggerAnsiDiv('divPlan','dp1'); <?php echo $s; ?>
<?php require "www2-funcs.php"; login_init(); page_header("讯息回寄"); assert_login(); $filename = bbs_sethomefile($currentuser["userid"], "msgindex"); if (file_exists($filename)) { unlink($filename); } $filename = bbs_sethomefile($currentuser["userid"], "msgindex2"); if (file_exists($filename)) { unlink($filename); } $filename = bbs_sethomefile($currentuser["userid"], "msgcount"); if (file_exists($filename)) { unlink($filename); } html_success_quit("已经删除所有讯息备份");
<?php require "www2-funcs.php"; login_init(); bbs_session_modify_user_mode(BBS_MODE_EDITUFILE); toolbox_header("黑名单"); assert_login(); $fname = bbs_sethomefile($currentuser["userid"], "ignores"); if (isset($_POST["badlist"])) { $empty = ""; for ($i = 0; $i < BBS_IDLEN; $i++) { $empty .= ""; } $badlist = explode("\n", $_POST["badlist"]); $count = count($badlist); $badstr = ""; $user = array(); $reallist = array(); $rid = 0; for ($i = 0; $i < $count; $i++) { $userid = trim($badlist[$i]); if (bbs_getuser($userid, $user)) { if ($currentuser["userid"] == $user["userid"]) { break; } $repeat = 0; for ($j = 0; $j < $rid; $j++) { if ($reallist[$j] == $user["userid"]) { $repeat = 1; break; }
<?php require "www2-funcs.php"; login_init(); bbs_session_modify_user_mode(BBS_MODE_EDITUFILE); toolbox_header("说明档修改"); assert_login(); $filename = bbs_sethomefile($currentuser["userid"], "plans"); if (isset($_POST['text'])) { $fp = @fopen($filename, "w+"); if ($fp !== false) { fwrite($fp, str_replace("\r\n", "\n", $_POST["text"])); fclose($fp); html_success_quit($currentuser["userid"] . "说明档修改成功"); } html_error_quit("系统错误"); } ?> <form method="post" action="bbsplan.php" class="large"> <fieldset><legend>修改说明档</legend> <textarea name="text" onkeydown='return textarea_okd(this, event);' wrap="physical" id="sfocus"> <?php echo @htmlspecialchars(file_get_contents($filename)); ?> </textarea> </fieldset> <div class="oper"> <input type="submit" value="存盘" /> <input type="reset" value="复原" /> </div> </form> <?php
/** * function getHome get the path of current user in file system * * @param string $file * @return string * @access public */ public function getHome($file = null) { if (is_null($file)) { return bbs_sethomefile($this->userid); } return bbs_sethomefile($this->userid, $file); }