You are here

function parser_common_syndication_requirements in FeedAPI 5

Implementaton of hook_requirements().

File

parser_common_syndication/parser_common_syndication.module, line 68
Parse the incoming URL with SimpleXML then provide a data structure of the feed. Requires PHP5 because of SimpleXML.

Code

function parser_common_syndication_requirements() {
  $t = get_t();
  if (!version_compare(5, PHP_VERSION, '<=') || !function_exists('simplexml_load_file')) {
    return array(
      'Parser Common Syndication' => array(
        'title' => t('SimpleXML library.'),
        'description' => t('A fast XML parsing library. (From PHP5)'),
        'severity' => REQUIREMENT_ERROR,
        'value' => $t('Missing'),
      ),
    );
  }
  return array(
    'Parser Common Syndication' => array(
      'title' => t('SimpleXML library.'),
      'description' => t('A fast XML parsing library. (From PHP5)'),
      'severity' => REQUIREMENT_OK,
      'value' => $t('Available'),
    ),
  );
}