Advertisement
Guest User

Untitled

a guest
Mar 24th, 2017
153
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.98 KB | None | 0 0
  1. <?php
  2. session_start();
  3. $username="user";
  4. $password="123";
  5.  
  6. if($_POST['username'] == $username && $_POST['password'] == $password)
  7. header( 'Location: ../admin.php' );
  8. else echo "Incorrect login information. Please try again."
  9. ?>
  10.  
  11. <html>
  12.     <head>
  13.     </head>
  14.     <body>
  15.         <div style='text-align:left'>
  16.         </div>
  17.         <hr /><br />
  18.         <form id='login' action="" method='post' accept-charset='UTF-8'>
  19.             <fieldset style="width:550px">
  20.             <legend>Admin Login</legend>
  21.             <input type='hidden' name='submitted' id='submitted' value='1'/>
  22.  
  23.             <label for='username' >UserName:</label>
  24.             <input type='text' name='username' id='username'  maxlength="50" />
  25.  
  26.  
  27.             <label for='password' >Password:</label>
  28.             <input type='password' name='password' id='password' maxlength="50" />
  29.  
  30.             <input type='submit' name='submit' value='Submit' />
  31.             </fieldset>
  32.         </form>
  33.     </body>
  34. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement