You are here

function hosting_format_interval in Hosting 5

Same name and namespace in other branches
  1. 6.2 hosting.inc \hosting_format_interval()
  2. 7.4 hosting.inc \hosting_format_interval()
  3. 7.3 hosting.inc \hosting_format_interval()
7 calls to hosting_format_interval()
hosting_cron_nodeapi in cron/hosting_cron.module
hosting_platform_view in platform/hosting_platform.module
Implementation of hook_view().
hosting_queues_configure in ./hosting.module
Page callback
hosting_queue_summary_block in ./hosting.module
hosting_site_view in site/hosting_site.module

... See full list

File

./hosting.module, line 336
Hosting module

Code

function hosting_format_interval($ts) {
  if ($ts == mktime()) {
    return t('Now');
  }
  if (!$ts) {

    //Treats EPOCH as never
    return t('Never');
  }
  return t("@interval ago", array(
    "@interval" => format_interval(mktime() - $ts, 1),
  ));
}