http://www.codefundamentals.com/cadeui/login.php
<?php
require_once($_SERVER['DOCUMENT_ROOT']."/cadeui/system/includes/db-config.php");
$page="Login";
require_once($_SERVER['DOCUMENT_ROOT']."/cadeui/system/includes/header.php");
?>
<body id="login-page">
<div class="login-wrapper">
<div class="logo">
<img src="http://guelphtoyota.com/wordpress/wp-content/uploads/2012/09/blank-profile.png" alt="CadeUI Logo">
<h1>CadeUI</h1>
</div>
<form method="post" action="<?php echo $_SERVER['PHP_SELF'];?>" id="login" name="login">
<fieldset>
<label for"email">Username</label>
<input type="text" class="envelope" placeholder="Username" id="email" name="email">
<div class="password-holder">
<label for="password">Password</label>
<span class="showHide showPW remove">Show</span>
</div>
<input type="password" class="lock" placeholder="Password" id="password" name="password">
<div class="submit-holder">
<a href="#" class="forgotpw">I forgot my password...</a>
<input type="submit" id="submit" value="Login">
</div>
</fieldset>
</form>
</div>
<?php
if(isset($_POST['login']))
{
$pdo=new PDO('mysql:dbname=codefund_user_login', 'codefund', 'pw!');
$login = new LoginRepository($pdo);
if($login->checkCredentials($_POST['email'],$_POST['password']))
echo "login went good";
}
require_once($_SERVER['DOCUMENT_ROOT']."/cadeui/system/includes/js-files.php");
?>
</body>
</html>
I notice that when I login with
admin@codefundamentals.com
password
I try logging in again and it doesnât give that alert letting me know it was successful. Playing with it it just doesnât work 100% of the time. Can anyone identify why? Also, anything youâd change about the ajax login?
Edit-Not working at all now?