function short_answer_config_validate in Quiz 7.5
Same name and namespace in other branches
- 8.6 question_types/quiz_short_answer/quiz_short_answer.module \short_answer_config_validate()
- 8.4 question_types/short_answer/short_answer.module \short_answer_config_validate()
- 8.5 question_types/quiz_short_answer/quiz_short_answer.module \short_answer_config_validate()
- 7.6 question_types/short_answer/short_answer.module \short_answer_config_validate()
- 7.4 question_types/short_answer/short_answer.module \short_answer_config_validate()
Validate the short_answer config form values.
1 string reference to 'short_answer_config_validate'
- short_answer_quiz_question_config in question_types/
short_answer/ short_answer.module - Implements hook_quiz_question_config().
File
- question_types/
short_answer/ short_answer.module, line 67 - Short_answer question type for the Quiz module.
Code
function short_answer_config_validate($form, $form_state) {
if ($form_state['values']['short_answer_default_max_score'] <= 0) {
form_set_error('short_answer_default_max_score', t('The default max score must be greater than 0'));
}
}