You are here

function theme_custom_pager in Custom Pagers 5

2 theme calls to theme_custom_pager()
custom_pagers_block in ./custom_pagers.module
Implementation of hook_block().
custom_pagers_nodeapi in ./custom_pagers.module

File

./custom_pagers.module, line 513

Code

function theme_custom_pager($nav_array, $node, $pager) {
  drupal_add_css(drupal_get_path('module', 'custom_pagers') . '/custom_pagers.css');
  $links = array();
  $links['custom_pager_prev'] = array(
    'title' => t('‹ previous'),
    'href' => !empty($nav_array['prev']) ? 'node/' . $nav_array['prev'] : NULL,
  );
  $links['custom_pager_index'] = array(
    'title' => t('@count of @count_total', array(
      '@count' => $nav_array['current_index'] + 1,
      '@count_total' => count($nav_array['full_list']),
    )),
  );
  $links['custom_pager_next'] = array(
    'title' => t('next ›'),
    'href' => !empty($nav_array['next']) ? 'node/' . $nav_array['next'] : NULL,
  );
  return theme('links', $links, array(
    'class' => "custom-pager custom-pager-{$pager->pid} custom-pager-{$node->type}",
  ));
}