Place Pager at top and bottom of Views view.

Place Pager at top and bottom of Views view.

Categories:

This code helps you place the pager at top and bottom of your views.

Copy and paste this code into your template.php file.

<?php
function phptemplate_views_view($view, $type, $nodes, $level = NULL, $args = NULL){
   
$output = '';
    if (
$view->use_pager) {
       
$output .= theme('pager', '', $view->pager_limit, $view->use_pager - 1);
    }

   
$output .= theme_views_view($view, $type, $nodes, $level = NULL, $args = NULL);

    return
$output;
}
?>

Tested in drupal 4.x and 5.x

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.
  • You may post code using <code>...</code> (generic) or <?php ... ?> (highlighted PHP) tags.

More information about formatting options

CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.
6 + 0 =
Solve this simple math problem and enter the result. E.g. for 1+3, enter 4.