printerror("DbError", "history.go(-1)"); } } $gr = $empire->fetch1("select dochadminstyle from {$dbtbpre}enewsgroup where groupid='{$loginlevel}'"); $enews = $_POST['enews']; if (empty($enews)) { $enews = $_GET['enews']; } //修改密码 if ($enews == "EditPassword") { $oldpassword = $_POST['oldpassword']; $password = $_POST['password']; $repassword = $_POST['repassword']; $styleid = (int) $_POST['styleid']; $oldstyleid = (int) $_POST['oldstyleid']; EditPassword($logininid, $loginin, $oldpassword, $password, $repassword, $styleid, $oldstyleid, $_POST); } $r = $empire->fetch1("select userid,styleid,truename,email from {$dbtbpre}enewsuser where userid='{$logininid}'"); $addur = $empire->fetch1("select equestion from {$dbtbpre}enewsuseradd where userid='{$r['userid']}'"); if ($gr['dochadminstyle']) { //后台样式 $stylesql = $empire->query("select styleid,stylename,path from {$dbtbpre}enewsadminstyle order by styleid"); $style = ""; while ($styler = $empire->fetch($stylesql)) { if ($r[styleid] == $styler[styleid]) { $sselect = " selected"; } else { $sselect = ""; } $style .= "<option value=" . $styler[styleid] . $sselect . ">" . $styler[stylename] . "</option>"; }
Unauthorized(); } // What section do they want to view? switch ($_REQUEST['section']) { case 'profile': $strSection = $_REQUEST['section']; EditProfile(); case 'options': $strSection = $_REQUEST['section']; EditOptions(); case 'avatar': $strSection = $_REQUEST['section']; EditAvatar(); case 'password': $strSection = $_REQUEST['section']; EditPassword(); case 'buddylist': $strSection = $_REQUEST['section']; EditBuddyList(); case 'ignorelist': $strSection = $_REQUEST['section']; EditIgnoreList(); default: $strSection = 'index'; ShowIndex(); } // *************************************************************************** \\ function ShowIndex() { global $CFG, $dbConn, $aPostIcons; // Constants
<?php include_once "conn.php"; include_once "function.php"; if ($_GET["action"] == "") { exit; } if ($_GET["action"] == "register") { echo Register($_GET["phonenum"], $_GET["password"]); } if ($_GET["action"] == "login") { echo Login($_GET["phonenum"], $_GET["password"]); } if ($_GET["action"] == "edit_password") { echo EditPassword($_GET["phonenum"], $_GET["password"]); } if ($_GET["action"] == "add_guardian") { echo AddGuardian($_GET["phonenum"], $_GET["guardiantel"]); } if ($_GET["action"] == "del_guardian") { echo DelGuardian($_GET["phonenum"], $_GET["guardiantel"]); } if ($_GET["action"] == "get_guardian") { echo GetGuardian($_GET["phonenum"]); } if ($_GET["action"] == "add_record") { echo AddRecord($_GET["phonenum"], $_GET["value"], $_GET["food"], $_GET["sport"], $_GET["medicine"], $_GET["round"]); } if ($_GET["action"] == "get_record") { echo GetRecord($_GET["phonenum"], $_GET["starttime"], $_GET["endtime"]); }