Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- session_start();
- $error='';
- if (isset($_POST['submit'])) {
- if (empty($_POST['username']) || empty($_POST['password'])) {
- $error = "Username or Password is invalid";
- } else {
- $username = $_POST['username'];
- $password = $_POST['password'];
- $username = ($username);
- $password = ($password);
- if ($rows == 1) {
- $_SESSION['login_user'] = $username;
- header("location: profile.php");
- } else {
- $error = "Username or Password is invalid";
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement