cluce Posted May 14, 2007 Share Posted May 14, 2007 I am trying to count the number of unsuccessful logins. Can someone tell me would be the syntax to increment this in a table? How could I add to the current value? Or would do an INSERT? can someone give me some direction? here is my code //redirect back to login form if not authorized $_SESSION['error'] = "<font color='red'>invalid username and/or password combination</font>"; $sql3 = "UPDATE auth_users SET failed_logins = WHERE username = '".$_POST["username"]."'"; header("Location: user_logon.php"); exit; } Quote Link to comment Share on other sites More sharing options...
Dragen Posted May 14, 2007 Share Posted May 14, 2007 I believe it would be: //redirect back to login form if not authorized $_SESSION['error'] = "<font color='red'>invalid username and/or password combination</font>"; $sql3 = "UPDATE auth_users SET failed_logins = failed_logins + 1 WHERE username = '".$_POST["username"]."'"; header("Location: user_logon.php"); exit; } Quote Link to comment Share on other sites More sharing options...
cluce Posted May 14, 2007 Author Share Posted May 14, 2007 thats what I thought that was simple enough....thanks Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.