function mobile_number_requirements in Mobile Number 7
Same name and namespace in other branches
- 8 mobile_number.install \mobile_number_requirements()
- 2.0.x mobile_number.install \mobile_number_requirements()
Implements hook_requirements().
File
- ./
mobile_number.install, line 107 - Install, update and uninstall functions for the systementity_configfield module.
Code
function mobile_number_requirements($phase) {
$requirements = array();
module_load_include('inc', 'mobile_number', 'include/mobile_number.libphonenumber');
switch ($phase) {
case 'runtime':
$requirements['mobile_number'] = array(
'title' => t('Mobile Number Requirements'),
'description' => t('!libphonenumber library installation.', array(
'!libphonenumber' => l(t('libphonenumber'), 'https://github.com/giggsey/libphonenumber-for-php', array(
'attributes' => array(
'target' => '_blank',
),
)),
)),
'severity' => class_exists('\\libphonenumber\\PhoneNumberUtil') ? REQUIREMENT_OK : REQUIREMENT_ERROR,
'value' => class_exists('\\libphonenumber\\PhoneNumberUtil') ? t('Installed.') : t('Not installed.'),
);
break;
}
return $requirements;
}