function file_entity_admin_files_validate in File Entity (fieldable files) 7
Same name and namespace in other branches
- 7.3 file_entity.admin.inc \file_entity_admin_files_validate()
- 7.2 file_entity.admin.inc \file_entity_admin_files_validate()
Validate file_entity_admin_files form submissions.
Check if any files have been selected to perform the chosen 'Update option' on.
File
- ./
file_entity.admin.inc, line 132 - Administrative interface for file type configuration.
Code
function file_entity_admin_files_validate($form, &$form_state) {
$files = array_filter($form_state['values']['files']);
if (count($files) == 0) {
form_set_error('', t('Update operation failed: no files were selected.'));
}
}