function textimage_settings_form_validate in Textimage 5.2
Same name and namespace in other branches
- 5 textimage.module \textimage_settings_form_validate()
- 6.2 textimage_admin.inc \textimage_settings_form_validate()
- 7.2 textimage.admin.inc \textimage_settings_form_validate()
File
- ./
textimage_admin.inc, line 47
Code
function textimage_settings_form_validate($form_id, $form_values) {
// Check for valid fonts path.
if ($form_values['textimage_fonts_path'] != "" && !is_dir(rtrim($form_values['textimage_fonts_path'], '\\/'))) {
form_set_error('textimage_fonts_path', t('The fonts path "%path" is invalid.', array(
'%path' => $form_values['textimage_fonts_path'],
)));
}
// Check for valid backgorund images path.
if ($form_values['textimage_images_path'] != "" && !is_dir(rtrim($form_values['textimage_images_path'], '\\/'))) {
form_set_error('textimage_images_path', t('The background images path "%path" is invalid.', array(
'%path' => $form_values['textimage_fonts_path'],
)));
}
}