($bannedIp['banExpiry'] != null ? coreFunctions::formatDate($bannedIp['banExpiry']) : t('later', 'later'))))); } } // initial validation if (notification::isErrors() == false) { if (!strlen($loginUsername)) { // log failure Auth::logFailedLoginAttempt(coreFunctions::getUsersIPAddress(), $loginUsername); notification::setError(t("please_enter_your_username", "Please enter your username")); } elseif (!strlen($loginPassword)) { // log failure Auth::logFailedLoginAttempt(coreFunctions::getUsersIPAddress(), $loginUsername); notification::setError(t("please_enter_your_password", "Please enter your password")); } } // check captcha if ((!notification::isErrors()) && (SITE_CONFIG_CAPTCHA_LOGIN_SCREEN_NORMAL == 'yes')) { if (!isset($_REQUEST['g-recaptcha-response'])) { notification::setError(t("invalid_captcha123", "Captcha confirmation text is invalid.")); } else { $resp = coreFunctions::captchaCheck($_REQUEST["g-recaptcha-response"]); if ($resp == false) { notification::setError(t("invalid_captcha", "Captcha confirmation text is invalid.")); } } } if (notification::isErrors() == false) { $rs = $Auth->login($loginUsername, $loginPassword, true); if ($rs) { // if we know the file if (isset($_REQUEST['loginShortUrl'])) { // download file $file = file::loadByShortUrl(trim($_REQUEST['loginShortUrl'])); if ($file) { coreFunctions::redirect($file->getFullShortUrl()); } } // successful login coreFunctions::redirect(coreFunctions::getCoreSitePath() . '/account_home.' . SITE_CONFIG_PAGE_EXTENSION); } else { // login failed notification::setError(t("username_and_password_is_invalid", "Your username and password are invalid")); } } } ?> getThemeSkin(); $homepageBackgroundImageUrl = $themeObj->getHomepageBackgroundImageUrl(); $homepageBackgroundVideoUrl = $themeObj->getHomepageBackgroundVideoUrl(); // top navigation require_once(SITE_TEMPLATES_PATH . '/partial/_navigation_header.inc.php'); ?>