function mythemename_pager_next($text, $limit, $element = 0, $interval = 1, $parameters = array()) { global $pager_page_array, $pager_total; $output = ''; // If we are anywhere but the last page if ($pager_page_array[$element] < ($pager_total[$element] - 1)) { $page_new = pager_load_array($pager_page_array[$element] + $interval, $element, $pager_page_array); // If the next page is the last page, mark the link as such. if ($page_new[$element] == ($pager_total[$element] - 1)) { $output = theme('pager_last', $text, $limit, $element, $parameters); // The next page is not the last page. } else { $output = theme('pager_link', $text, $page_new, $element, $parameters); //$output = '<li class="custom-pager-next"><a class="active" href="javascript: void(0)"><img width="10" height="19" title="" alt="Previous" src="/' . path_to_theme() . '/img/pager-previous.png"></a></li>'; } } return $output;
}
How to make NEXT PAGE link visible on last page? For example we have 3 pages and i am on the 3rd page and i should see NEXT page link. Please assist to me with function above, thanks!