MDL-39029 quiz password: autofocus feature added
authorJayesh Anandani <jayeshanandani@gmail.com>
Thu, 11 Apr 2013 10:55:34 +0000 (16:25 +0530)
committerJayesh Anandani <jayeshanandani@gmail.com>
Thu, 11 Apr 2013 11:56:58 +0000 (17:26 +0530)
mod/quiz/accessrule/password/rule.php

index a7490d9..778e390 100644 (file)
@@ -64,7 +64,7 @@ class quizaccess_password extends quiz_access_rule_base {
         // Don't use the 'proper' field name of 'password' since that get's
         // Firefox's password auto-complete over-excited.
         $mform->addElement('password', 'quizpassword',
-                get_string('quizpassword', 'quizaccess_password'));
+                get_string('quizpassword', 'quizaccess_password'), array('autofocus' => 'true'));
     }
 
     public function validate_preflight_check($data, $files, $errors, $attemptid) {