function feed_import_element_validate_simplexmlclass in Feed Import 8
Same name and namespace in other branches
- 7.3 feed_import.module \feed_import_element_validate_simplexmlclass()
Validates class name to be instance of SimpleXMLElement
1 string reference to 'feed_import_element_validate_simplexmlclass'
- feed_import_feed_import_reader_info in ./
feed_import.module - Implements hook_feed_import_reader_info().
File
- ./
feed_import.module, line 637 - User interface, cron functions for feed_import module.
Code
function feed_import_element_validate_simplexmlclass($element, &$form_state, $form) {
if (!$element['#value']) {
return;
}
if ($element['#value'] != 'SimpleXMLElement' && !is_subclass_of($element['#value'], 'SimpleXMLElement')) {
form_error($element, t('%title must extend SimpleXMLElement class!', array(
'%title' => $element['#title'],
)));
}
}