Beispiel #1
0
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->register($email, $password)) {
        $info = $info . 'Signup Successful. Please proceed to Login <a href="../signin/"> here</a>';
        $registered = true;
    } 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>Singup!</title>
	<link href="style.css" rel="stylesheet"/>
</head>
<body>