You are here

function mostpopular_interval_title in Drupal Most Popular 7

Returns the full title, which is the interval's title prepended with 'Past '. So, for instance, 'Day' becomes 'Past Day'.

Return value

string The full title of the interval.

1 call to mostpopular_interval_title()
mostpopular_intervals_admin_form_submit in ./mostpopular.intervals.inc

File

./mostpopular.module, line 606
The main file for the Most Popular module.

Code

function mostpopular_interval_title($interval) {
  if (is_int($interval)) {
    $interval = mostpopular_intervals($interval);
  }
  if (!$interval) {
    return '';
  }
  return 'Past ' . $interval->title;
}