function _filefield_sources_form_include in FileField Sources 7
Ensure that a source include file is loaded into $form_state.
2 calls to _filefield_sources_form_include()
- filefield_sources_field_process in ./
filefield_sources.module - A #process callback to extend the filefield_widget element type.
- filefield_sources_form in ./
filefield_sources.module - Configuration form for editing FileField Sources settings for a widget.
File
- ./
filefield_sources.module, line 733 - Extend FileField to allow files from multiple sources.
Code
function _filefield_sources_form_include($module, $filepath, &$form_state) {
$last_dot = strrpos($filepath, '.');
$path = substr($filepath, 0, $last_dot);
$extension = substr($filepath, $last_dot + 1);
form_load_include($form_state, $extension, $module, $path);
}