public static function FeedImport::processJSONValidate in Feed Import 7.2
Callback for validating processJSON settings
File
- ./
feed_import.inc.php, line 1588 - Feed import class for parsing and processing content.
Class
- FeedImport
- @file Feed import class for parsing and processing content.
Code
public static function processJSONValidate($field, $value, $default = NULL) {
$value = trim($value);
if (!preg_match("/^\\<\\?xml (.*)\\?\\>\\<([a-zA-Z]+)\\/\\>\$/", $value)) {
return $default;
}
return $value;
}