theme_pager_first

Definition

theme_pager_first($text, $limit, $element = 0, $parameters = array())
includes/pager.inc, line 151

Description

Format a "first page" link.

Parameters

$text The name (or image) of the link.

$limit The number of query results to display per page.

$element An optional integer to distinguish between multiple pagers on one page.

$parameters An associative array of query string parameters to append to the pager links.

Return value

An HTML string that generates this piece of the query pager.

Related topics

Namesort iconDescription
Themeable functionsFunctions that display HTML, and which can be customized by themes.

Code

<?php
function theme_pager_first($text, $limit, $element = 0, $parameters = array()) {
  global $pager_page_array;
  $output = '';

  // If we are anywhere but the first page
  if ($pager_page_array[$element] > 0) {
    $output = theme('pager_link', $text, pager_load_array(0, $element, $pager_page_array), $element, $parameters, array('class' => 'pager-first'));
  }

  return $output;
}
?>
 
 

All source code and documentation on this site is released under the terms of the GNU General Public License, version 2 and later. Drupal is a registered trademark of Dries Buytaert.