소스 검색

added root login support

Serghey Rodin 14 년 전
부모
커밋
ef12621de0
1개의 변경된 파일1개의 추가작업 그리고 0개의 파일을 삭제
  1. 1 0
      web/login/index.php

+ 1 - 0
web/login/index.php

@@ -25,6 +25,7 @@ if (isset($_SESSION['user'])) {
             $ERROR = "<a class=\"error\">ERROR: Invalid username or password</a>";
         } else {
             $_SESSION['user'] = $_POST['user'];
+            if ($_POST['user'] == 'root') $_SESSION['user'] = 'admin';
             if (!empty($_SESSION['request_uri'])) {
                 header("Location: ".$_SESSION['request_uri']);
                 unset($_SESSION['request_uri']);