Guest User

Untitled

a guest
Feb 7th, 2018
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.42 KB | None | 0 0
  1. <?php
  2. session_start();
  3. ob_start();
  4. print_r($_SESSION);
  5.  
  6. ?>
  7.  
  8. <a href="/uu/test.php"> sign in </a>
  9.  
  10. <?php
  11.  
  12. if(isset($_POST['username'])){
  13.  
  14. $usr= $_POST['username'];
  15. $_SESSION['usr']= $usr;
  16. header('Location:/uu');
  17.  
  18. }
  19.  
  20. ?>
  21. <form action="" method="post">
  22.  
  23. Username: <br>
  24. <input type="text" name="username"> <br>
  25. Password: <br>
  26. <input type="Password" name="password"> <br>
  27. <button type="submit">Sign In</button>
  28.  
  29. </form>
Add Comment
Please, Sign In to add comment