/**
* Sends confirmation email to the student taking the course
*
- * @param stdClass $a associative array of replaceable fields for the templates
+ * @param object $a associative array of replaceable fields for the templates
*
- * @return bool|string result of events_triger
+ * @return bool
*/
function quiz_send_confirmation($a) {
* Sends notification messages to the interested parties that assign the role capability
*
* @param object $recipient user object of the intended recipient
- * @param stdClass $a associative array of replaceable fields for the templates
+ * @param object $a associative array of replaceable fields for the templates
*
- * @return bool|string result of events_triger()
+ * @return bool
*/
function quiz_send_notification($recipient, $a) {
*/
M.core_question_engine.init_form = function(Y, form) {
Y.one(form).setAttribute('autocomplete', 'off');
+
+ Y.on('submit', M.core_question_engine.prevent_repeat_submission, form, form, Y);
+
Y.on('key', function (e) {
if (!e.target.test('a') && !e.target.test('input[type=submit]') &&
- !e.target.test('input[type=img]')) {
+ !e.target.test('input[type=img]') && !e.target.test('textarea')) {
e.preventDefault();
}
}, form, 'press:13');