Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $username = 'michel';
- $password = '$2y$10$Da2gQ3ci2FsgfWXijqwwGuJYg1H.gHjkMrNjFIo0MPiN.xuIU3dWa';
- if(isset($_POST['submit']))
- {
- if(strlen($_POST['username']) < 1 || strlen($_POST['password']) < 1)
- {
- echo 'OHOI je hebt iets leeg gelaten';
- }
- else
- {
- if($_POST['username'] == $username && password_verify($_POST['password'], $password))
- {
- echo 'Login data was succesvol! Je bent ingelogd!';
- }
- else {
- echo 'OHOI we konden je niet inloggen!';
- }
- }
- }
- ?>
- <form method="post">
- <input type="text" name="username" placeholder="Gerbuikersnaam">
- <input type="password" name="password" placeholder="Wachtwoord">
- <input type="submit" name="submit" value="Log in">
- </form>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement