function resource_conflict_form_validate in Resource Conflict 7.3
Same name and namespace in other branches
- 5.2 resource_conflict.module \resource_conflict_form_validate()
- 6.2 resource_conflict.module \resource_conflict_form_validate()
- 7.2 resource_conflict.module \resource_conflict_form_validate()
Our custom validate handler for when a content type is saved.
1 string reference to 'resource_conflict_form_validate'
- resource_conflict_form_alter in ./
resource_conflict.module - Implements hook_form_alter().
File
- ./
resource_conflict.module, line 308 - Provides general functionality for the resource conflict module.
Code
function resource_conflict_form_validate($form, &$form_state) {
if (!empty($form_state['values']['rc_conflict_buffer_start'])) {
if (strtotime($form_state['values']['rc_conflict_buffer_start']) === FALSE) {
form_set_error('rc_conflict_buffer_start', t('Start buffer not valid. Check PHP documentation for strtotime().'));
}
}
if (!empty($form_state['values']['rc_conflict_buffer_end'])) {
if (strtotime($form_state['values']['rc_conflict_buffer_end']) === FALSE) {
form_set_error('rc_conflict_buffer_end', t('End buffer not valid. Check PHP documentation for strtotime().'));
}
}
}