<a class="navbar-brand" href="#">试题选择</a> </div> <div id="navbar" class="navbar-collapse collapse"> <ul class="nav navbar-nav"> <li><a href="#">主页</a></li> <li class="active"><a href="#about">试题选择</a></li> <li><a href="#contact">帮助</a></li> </ul> <ul class="nav navbar-nav navbar-right"> <li class="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"> <?php include_once '../BLL/userBll.php'; session_start(); $userID = $_SESSION['userID']; $userList = FindbyUserId($userID); echo $userList[0][1]; ?> <span class="caret"></span></a> <ul class="dropdown-menu"> <li><a href="#">个人资料</a></li> <li><a href="showAllResult.php">测试结果</a></li> </ul> </li> </ul> </div><!--/.nav-collapse --> </div> </nav> <div class="container">
} } else { echo "<script>alert('password must be 6~20 bytes!'); history.go(-1);</script>"; } } } else { if ($psw == "" || $psw_confirm == "" || $realname == "") { echo "<script>alert('please check the information!'); history.go(-1);</script>"; } else { if (pass_validate($psw) && pass_validate($psw_confirm)) { if ($psw == $psw_confirm) { if (IsUserExists($realname)) { if (ModifyPassword($realname, $psw)) { session_start(); $_SESSION['user'] = $realname; $result = FindbyUserId($realname); $identify = $result[0][4]; if ($identify == '') { echo "<script>alert('Success,go to the index!');window.location.href = 'http://2.whoisyourdaddy.sinaapp.com/index.php?s=/addon/WeiSite/WeiSite/index/publicid/154.html';</script>"; } else { echo "<script>alert('Success,go to the index!');window.location.href = 'http://2.whoisyourdaddy.sinaapp.com/index.php?s=/addon/WeiSite/WeiSite/index/publicid/154.html';</script>"; } // echo "<a href=''>返回</a>"; } else { echo "<script>alert('System Busy'); history.go(-1);</script>"; } } else { echo "<script>alert('该用户不存在!'); history.go(-1);</script>"; } } else { echo "<script>alert('两次输入的密码不同!'); history.go(-1);</script>";
<?php include_once '../BLL/userBll.php'; if (isset($_POST["submit"]) && $_POST["submit"] == "登录") { $user = $_POST["username"]; $psw = $_POST["password"]; if ($user == "" || $psw == "") { echo "<script>alert('请输入用户名或密码!'); history.go(-1);</script>"; } else { if (CheckUser($user, $psw)) { $result = FindbyUserId($user); $authority = $result[0][5]; $userId = $result[0][0]; session_start(); $_SESSION['userID'] = $userId; //echo "success!!"; if ($authority == 2) { echo "<script>window.location.href = '../UIL/ManageIndex.php';</script>"; } else { $identify = $result[0][4]; if ($identify == '') { echo "<script>window.location.href = 'http://2.whoisyourdaddy.sinaapp.com/index.php?s=/addon/WeiSite/WeiSite/index/publicid/154.html';</script>"; } else { echo "<script>window.location.href = 'http://2.whoisyourdaddy.sinaapp.com/index.php?s=/addon/WeiSite/WeiSite/index/publicid/154.html';</script>"; } } } else { echo "<script>alert('wrong password!');history.go(-1);</script>"; } } } else {