Advertisement
Guest User

Untitled

a guest
Nov 20th, 2017
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?php session_start(); //always make sure takde extra spaces sebelum session_start
  2. if(isset($_SESSION['idrole'])){
  3. if(I$_SESSION['idrole']== 1)
  4. {
  5. header("Location: ../technician/index.php");
  6. }
  7. if($_SESSION['idrole']== 2)
  8. {
  9. header("Location: ../clerk/index.php");
  10. }
  11. if($_SESSION['idrole']== 3)
  12. {
  13. header("Location: ../director/index.php");
  14. }
  15. }
  16.  
  17. ?>
  18.  
  19. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  20. <html xmlns="http://www.w3.org/1999/xhtml">
  21. <head>
  22. <meta name="viewport" content="width=device-width, initial-scale=1">
  23. <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
  24. <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
  25. <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
  26. <title>PCC Login</title>
  27. </head>
  28.  
  29. <body>
  30. <?php include 'header login.php';?>
  31. <div class="container">
  32. <div class="row">
  33. <div class="col-md-6 col-md-offset-3">
  34. <div class="panel panel-login">
  35. <div class="panel-heading">
  36. <div class="row">
  37. <div class="col-xs-6">
  38. <a href="login.php" class="active" id="loginlink">Login</a>
  39. </div>
  40. <div class="col-xs-6">
  41. <a href="register.php" id="registerlink">Register</a>
  42. </div>
  43. </div>
  44. <hr>
  45. </div>
  46. <div class="panel-body">
  47. <div class="row">
  48. <div class="col-lg-12">
  49. <form id="login-form" action="checklogin.php" method="post" role="form" style="display: block;">
  50. <div class="form-group">
  51. <input type="text" name="username" id="username" tabindex="1" class="form-control" placeholder="Username" required="required">
  52. </div>
  53. <div class="form-group">
  54. <input type="password" name="password" id="password" tabindex="2" class="form-control" placeholder="Password" required="required">
  55. </div>
  56. <div class="form-group text-center">
  57. <input type="checkbox" tabindex="3" class="" name="remember" id="remember">
  58. <label for="remember"> Remember Me</label>
  59. </div>
  60.  
  61. <div class="form-group">
  62. <div class="row">
  63. <div class="col-sm-6 col-sm-offset-3">
  64. <input type="submit" name="login-submit" id="login-submit" tabindex="4" class="form-control btn btn-login" value="Login">
  65. </div>
  66.  
  67. </div>
  68. </div>
  69.  
  70. </form>
  71.  
  72.  
  73. </div>
  74. </div>
  75. </div>
  76. </div>
  77. </div>
  78. </div>
  79. </div>
  80. </body>
  81. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement