diff --git a/login.php b/login.php index b237fa7..b9f2090 100644 --- a/login.php +++ b/login.php @@ -3,11 +3,7 @@ session_start(); if(isset($_SESSION['user'])) { header("Location: /home"); } -?> - - - - 0) { if (password_verify($password, $user->getPassword($con, $username))) { $_SESSION["user"] = $user->getID($con, $username); + header("Location: /home"); //echo $_SESSION["user"]; } else { $passwordiswrong = true; @@ -38,6 +35,9 @@ if(isset($_POST['submit'])) { $result = file_get_contents("https://useless-facts.sameerkumar.website/api"); $thefunfact = json_decode($result); ?> + + + <?php echo $pagename; ?> | <?php echo $sitename; ?> @@ -63,6 +63,7 @@ $thefunfact = json_decode($result); " type="password" placeholder="Your password (Minmum 8 characters)" id="inputSmall" name="pass"> Password is incorrect.'; } ?> + Don't have an account? Register here!