session_start(); include 'ViewController.class.php'; $control = new ViewController(); $email = ""; $password = ""; $info = " "; if (isset($_SESSION['auth'])) { // Existing User who is Already SignedIn header("location: ../dashboard/"); exit; } if (isset($_POST['login'])) { $email = trim($_POST['email']); $password = trim($_POST['password']); if ($control->login($email, $password)) { $_SESSION['auth'] = "1"; /* no message is require take em to the dashboard. let em create/moderate content! http://localhost:8888/contacts/admin/dashboard.php */ header("location: ../dashboard/"); exit; } else { $info = $info . $control->info; } } ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" dir="ltr" lang="en-US"> <head> <title>SignIn!</title>