[eluser]Phil Sturgeon[/eluser]
Well the two are slightly different, I preffer the second. Putting both checks in the DB makes things alot quicker and reduces the code alot. Why not chuck in some insensitivity checks?
Code:
"LOWER(username)` = '".strtolower($attempt->username)."'")