Question
php - login - make conditional to hide after 3 attempts
Hi I have my login but does anybody know how to make it
conditionally hide after 3 attempts to show a link to the lost
password page?
I thought about doing a recordset and applying the show if recordset behaviour but I don't think it can work this way.
I know I have to do some sort of counter using sessions but for which column in the database?
I am starting with this:
$_SESSION['count'] = $_SESSION['count'] + 1;
if ($_SESSION['counter'] > 3)
{
print '<a href="password.php" title="Lost Password">You seem to have lost your password, please click here to retrieve it.</a>';
exit;
}
but how to make the login form hide is where I am having trouble.
Does anybody have any suggestions?
I thought about doing a recordset and applying the show if recordset behaviour but I don't think it can work this way.
I know I have to do some sort of counter using sessions but for which column in the database?
I am starting with this:
$_SESSION['count'] = $_SESSION['count'] + 1;
if ($_SESSION['counter'] > 3)
{
print '<a href="password.php" title="Lost Password">You seem to have lost your password, please click here to retrieve it.</a>';
exit;
}
but how to make the login form hide is where I am having trouble.
Does anybody have any suggestions?
