function recipe_import_form_validate in Recipe 7.2
Same name and namespace in other branches
- 6 recipe.module \recipe_import_form_validate()
- 7 recipe.module \recipe_import_form_validate()
Form validation handler for recipe_import_form().
See also
File
- ./
recipe.admin.inc, line 210 - Contains admin page callbacks, form validation, and form submission handlers.
Code
function recipe_import_form_validate($form, &$form_state) {
// Make sure that they choose an import format.
// Otherwise the text entry is lost and the import fails with an error.
if (empty($form_state['values']['recipe_format'])) {
form_set_error('recipe_format', t('You must choose a recipe import format.'));
}
}