Explorar o código

Added detection of password fields in generic checkForm javascript function

pdontthink %!s(int64=22) %!d(string=hai) anos
pai
achega
355bab7631
Modificáronse 1 ficheiros con 2 adicións e 1 borrados
  1. 2 1
      functions/page_header.php

+ 2 - 1
functions/page_header.php

@@ -173,7 +173,8 @@ function displayPageHeader($color, $mailbox, $xtra='', $session=false) {
                     "var e = document.forms[i].elements.length;\n".
                     "var j = 0;\n".
                     "while( pos == -1 && j < e ) {\n".
-                        "if ( document.forms[i].elements[j].type == 'text' ) {\n".
+                        "if ( document.forms[i].elements[j].type == 'text' " .
+                        "|| document.forms[i].elements[j].type == 'password' ) {\n".
                             "pos = j;\n".
                         "}\n".
                         "j++;\n".