Happy New Year
[squirrelmail.git] / src / login.php
index e1d18a2eaffa68cf38959c30cae2de29cd1be3a7..835e8f4ddaf0cbcacf59a807fca76530ccc8f35e 100644 (file)
@@ -6,7 +6,7 @@
  * This a simple login screen. Some housekeeping is done to clean
  * cookies and find language.
  *
- * @copyright 1999-2011 The SquirrelMail Project Team
+ * @copyright 1999-2020 The SquirrelMail Project Team
  * @license http://opensource.org/licenses/gpl-license.php GNU Public License
  * @version $Id$
  * @package squirrelmail
@@ -63,7 +63,7 @@ $username_form_name = 'login_username';
 $password_form_name = 'secretkey';
 do_hook('login_cookie', $null);
 
-$loginname_value = (sqGetGlobalVar('loginname', $loginname) ? htmlspecialchars($loginname) : '');
+$loginname_value = (sqGetGlobalVar('loginname', $loginname) ? sm_encode_html_special_chars($loginname) : '');
 
 //FIXME: should be part of the template, not the core!
 /* Output the javascript onload function. */
@@ -100,7 +100,10 @@ if (! isset($color) || ! is_array($color)) {
     $color[8]  = '#000000';  /* black         Normal text            */
 }
 
-displayHtmlHeader( "$org_name - " . _("Login"), $header, FALSE );
+// if any plugin returns TRUE here, the standard page header will be skipped
+$temp = array($header);
+if (!boolean_hook_function('login_before_page_header', $temp, 1))
+    displayHtmlHeader( "$org_name - " . _("Login"), $header, FALSE );