You are here

function xmlsitemap_user_requirements in XML sitemap 5

Same name and namespace in other branches
  1. 6.2 xmlsitemap_user/xmlsitemap_user.install \xmlsitemap_user_requirements()
  2. 7.2 xmlsitemap_user/xmlsitemap_user.install \xmlsitemap_user_requirements()

Implementation of hook_requirements().

File

xmlsitemap_user/xmlsitemap_user.install, line 6

Code

function xmlsitemap_user_requirements($phase) {
  $t = get_t();
  $requirements = array();
  if (in_array($GLOBALS['db_type'], array(
    'mysql',
    'mysqli',
  )) && version_compare(db_version(), '4.0.14') < 0) {
    $requirements['xmlsitemap_user_sql'] = array(
      'title' => $t('XML Sitemap: User'),
      'value' => $t('Your MySQL version is too low. &ldquo;XML Sitemap: User&rdquo; requires MySQL 4.0.14 or higher.'),
      'severity' => REQUIREMENT_ERROR,
    );
  }
  return $requirements;
}