define('SERVER_URL', "http://www.mxchange.org");
// This current patch level
-define('CURR_SVN_REVISION', "347");
+define('CURR_SVN_REVISION', "348");
// Take a prime number which is long (if you know a longer one please try it out!)
define('_PRIME', 591623);
// @TODO Replace with own template!
OPEN_TABLE("500", "guest_login_header dashed", "center");
-OUTPUT_HTML("<br /><STRONG>".VALIDATING_LOGIN."</STRONG><br />");
+OUTPUT_HTML("<br /><strong>".VALIDATING_LOGIN."</strong><br />");
if (!empty($GLOBALS['userid']) && (isSessionVariableSet('u_hash')) && (isSessionVariableSet('lifetime'))) {
// Login failtures are supported since 0.4.7
// Remmeber login failtures if available
if (GET_EXT_VERSION("sql_patches") >= "0.4.7") {
+ // Reset login failtures
+ SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data
+SET login_failtures=0, last_failture='0000-00-00 00:00:00'
+WHERE userid=%s
+LIMIT 1",
+ array($GLOBALS['userid']), __FILE__, __LINE__);
+
// Store it in session
set_session('mxchange_member_failtures', $data['login_failtures']);
set_session('mxchange_member_last_fail', $data['last_failture']);
// Bonus is not given by default ;-)
$bonus = false;
if ((GET_EXT_VERSION("sql_patches") >= "0.2.8") && (GET_EXT_VERSION("bonus") >= "0.2.1") && ($_CONFIG['bonus_login_yn'] == "N") && ($_CONFIG['bonus_login_yn'] == "Y")) {
-
// Update last login if far enougth away
$result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data
SET last_login=UNIX_TIMESTAMP()
if (($bonus) && ($_GET['mode'] == "bonus") && (EXT_IS_ACTIVE("bonus"))) {
// Output message with added points
- OUTPUT_HTML("<FONT class=\"tiny\">
+ OUTPUT_HTML("<font class=\"tiny\">
".BONUS_LOGIN_BONUS_ADDED_1."
- <STRONG>".TRANSLATE_COMMA($_CONFIG['login_bonus'])." ".POINTS."</STRONG>
+ <strong>".TRANSLATE_COMMA($_CONFIG['login_bonus'])." ".POINTS."</strong>
".BONUS_LOGIN_BONUS_ADDED_2."
-</FONT>");
+</font>");
} elseif (EXT_IS_ACTIVE("bonus")) {
// No login bonus added!
- OUTPUT_HTML("<FONT class=\"member_failed\">".BONUS_LOGIN_BONUS_NOT_ADDED."</FONT>");
+ OUTPUT_HTML("<font class=\"member_failed\">".BONUS_LOGIN_BONUS_NOT_ADDED."</font>");
}
// Redirect to member area