Make the instantiation tests actually work.
[lhc/web/wiklou.git] / includes / HTMLForm.php
index c97b426..a6c7946 100644 (file)
@@ -66,7 +66,7 @@ class HTMLForm {
                'edittools' => 'HTMLEditTools',
        
                # HTMLTextField will output the correct type="" attribute automagically.
-               # There are about four zillion other HTML 5 input types, like url, but
+               # There are about four zillion other HTML5 input types, like url, but
                # we don't use those at the moment, so no point in adding all of them.
                'email' => 'HTMLTextField',
                'password' => 'HTMLTextField',
@@ -152,9 +152,9 @@ class HTMLForm {
        static function addJS() {
                if( self::$jsAdded ) return;
 
-               global $wgOut;
+               global $wgOut, $wgStylePath;
 
-               $wgOut->addScriptClass( 'htmlform' );
+               $wgOut->addScriptFile( "$wgStylePath/common/htmlform.js" );
        }
 
        /**