Guest User

Untitled

a guest
Aug 9th, 2018
121
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.45 KB | None | 0 0
  1. session is not woking in my login script
  2. <?php
  3. session_start();
  4. include '../../classes/check.class.php';
  5. include '../../classes/user.class.php';
  6.  
  7. $check = new Check();
  8. $user = new User();
  9.  
  10. $email = $_REQUEST['txtEmail'];
  11. $password = $_REQUEST['txtPassword'];
  12.  
  13. $userid = $check->validateUser($email, $password);
  14.  
  15. if($userid){
  16. $_SESSION['userid'] = $userid;
  17. $url = '../../index.php';
  18. header("Location: $url");
  19. }else{
  20. header("Location: $url");
  21. }
Add Comment
Please, Sign In to add comment