We have a form with php post redirecting communication to database and We'd like if there would have an easy method to detect if failed logins were doubt to username no exists or password dont match. say each error as separate option.
<form id="form1" action="doLogin.php" method="post">
<div id="border2">
<table class="table_text" cellpadding="2" cellspacing="0" border="0">
<tr>
<td>Username:</td>
<td><input type="text" name="username" class="input" /></td>
</tr>
<tr>
<td>Password:</td>
<td><input type="password" name="password" class="input" /></td>
</tr>
<tr>
<td colspan="2" align="right"><a target="_new" href="register.php">Register</a><input id="login_button" type="submit" name="submit" value="Login" class="button" /></td>
</tr>
</table>
</div>
</form>