function theme_locale_translation_last_check

Returns HTML for the last time we checked for update data.

In addition to properly formatting the given timestamp, this function also provides a "Check manually" link that refreshes the available update and redirects back to the same page.

Parameters

$variables: An associative array containing:

  • last: The timestamp when the site last checked for available updates.

See also

locale_translation_status_form()

Related topics

1 theme call to theme_locale_translation_last_check()
locale_translation_status_form in drupal/core/modules/locale/locale.pages.inc
Page callback: Display the current translation status.

File

drupal/core/modules/locale/locale.pages.inc, line 804
Interface translation summary, editing and deletion user interfaces.

Code

function theme_locale_translation_last_check($variables) {
  $last = $variables['last'];
  $output = '<div class="locale checked">';
  $output .= $last ? t('Last checked: @time ago', array(
    '@time' => format_interval(REQUEST_TIME - $last),
  )) : t('Last checked: never');
  $output .= ' <span class="check-manually">(' . l(t('Check manually'), 'admin/reports/translations/check', array(
    'query' => drupal_get_destination(),
  )) . ')</span>';
  $output .= "</div>\n";
  return $output;
}