瀏覽代碼

dont let signed in users create new users.

tags/rls1
kenn408k 6 年之前
父節點
當前提交
b9d35357e0
共有 1 個文件被更改,包括 4 次插入0 次删除
  1. 4
    0
      content/signup.php

+ 4
- 0
content/signup.php 查看文件

7
 
7
 
8
 Design::header($setup, 0);
8
 Design::header($setup, 0);
9
 
9
 
10
+if (User::checkLogin() == true) {
11
+    header('Location: '.Config::$sys_url.'?page=home');
12
+}
13
+
10
 if (isset($_POST['username'])) {
14
 if (isset($_POST['username'])) {
11
     if (Alter::addUser($_POST['username'],$_POST['password'],$_POST['realname'],$_POST['mail'],25)) {
15
     if (Alter::addUser($_POST['username'],$_POST['password'],$_POST['realname'],$_POST['mail'],25)) {
12
      // Success! User created - Redirect to login
16
      // Success! User created - Redirect to login

Loading…
取消
儲存