The Arcive of vBulletin Modifications Site. |
|
|
#1
|
||||
|
||||
|
Hello,
I want to change the strikes to 3 times and the time to wait to 25 Minutes. Is the code all in functions_login.php? Is this all? Code:
if ($strikes['strikes'] >= 3 AND $strikes['lasttime'] > TIMENOW - 1500)
{ //they've got it wrong 5 times or greater for any username at the moment
if (($strikes_user['strikes'] % 3 == 0) AND $user = $vbulletin->db->query_first("SELECT userid, username, email, languageid FROM " . TABLE_PREFIX . "user WHERE username = '" . $vbulletin->db->escape_string($username) . "' AND usergroupid <> 3"))
{ // they've got it wrong 5 times for this user lets email them
$ip = IPADDRESS;
eval(fetch_email_phrases('accountlocked', $user['languageid']));
vbmail($user['email'], $subject, $message, true);
}
// the user is still not giving up so lets keep increasing this marker
exec_strike_user($username);
if (!$supress_error)
{
eval(standard_error(fetch_error('strikes', $vbulletin->options['bburl'], $vbulletin->session->vars['sessionurl'])));
}
else
{
return false;
}
}
else if ($strikes['strikes'] > 3)
{ // a bit sneaky but at least it makes the error message look right
$strikes['strikes'] = 3;
}
Thanks, Tom |
|
#2
|
|||
|
|||
|
Why don't you just test it, on a test board, and find out?
|
|
#3
|
||||
|
||||
|
Outcome is a bit confusing, so I ask.
One account has 4 tries, another only 2 when I change it to a.m. code. Maybe same IP, maybe wrong code part... ? |
|
#4
|
||||
|
||||
|
anyone?
|
![]() |
|
|
| X vBulletin 3.8.12 by vBS Debug Information | |
|---|---|
|
|
More Information |
|
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|