Ejemplo n.º 1
0
include 'fontendClass/fontend.php';
include 'functions/toUppercase_function.php';
$fontend_object = new Fontend();
$email = "";
$password = "";
//check email validation
if (isset($_POST["email"]) && $_POST["email"] != "") {
    $email = mysqli_real_escape_string($fontend_object->conn, $_POST['email']);
}
//check password validation
if (isset($_POST["password"]) && $_POST["password"] != "") {
    $password = mysqli_real_escape_string($fontend_object->conn, $_POST['password']);
}
//call checkLogin function for user check
if ($email != "" && $password != "") {
    if ($fontend_object->checkLogin($email, $password)) {
        Header("Location: postpage.php");
    } else {
        echo "<script>alert('Email or Password mismatch.')</script>";
    }
}
?>
<html>
<head>
    <link rel="stylesheet" href="bootstrap.min.css">
    <!--for read more option-->
    <!--<script type="text/javascript" src="http://code.jquery.com/jquery.min.js"></script>-->
    <script type="text/javascript" src="jquery.min.js"></script>
    <script type="text/javascript">
        $(document).ready(function(){
            var maxLength = 200;