(bug 9835) password input should be type="password"
[lhc/web/wiklou.git] / includes / Xml.php
index 1d38c34..aeb9d5a 100644 (file)
@@ -164,6 +164,14 @@ class Xml {
                        'value' => $value ) + $attribs );
        }
 
+       /**
+        * Convenience function to build an HTML password input field
+        * @return string HTML
+        */
+       public static function password( $name, $size=false, $value=false, $attribs=array() ) {
+               return self::input( $name, $size, $value, array_merge($attribs, array('type' => 'password')));
+       }
+
        /**
         * Internal function for use in checkboxes and radio buttons and such.
         * @return array