function drush_ip2country_status in IP-based Determination of a Visitor's Country 7
Same name and namespace in other branches
- 8 ip2country.drush.inc \drush_ip2country_status()
Displays the time and RIR of the last database update.
File
- ./
ip2country.drush.inc, line 197
Code
function drush_ip2country_status() {
$update_time = variable_get('ip2country_last_update', 0);
if (!empty($update_time)) {
$message = dt('Database last updated on @date at @time from @registry server.', array(
'@date' => format_date($update_time, 'custom', variable_get('date_format_ip2country_date', 'n/j/Y')),
'@time' => format_date($update_time, 'custom', variable_get('date_format_ip2country_time', 'H:i:s T')),
'@registry' => drupal_strtoupper(variable_get('ip2country_last_update_rir', 'unknown')),
));
}
else {
$message = dt('Database is empty.');
}
drush_print($message);
}