Graham
Mwebvendor just extend the if statement for the buttons back to the original '4' buttons
http://syntax.xtgem.com/manual/basics/default?func=custom_paging
Mwebvendor
Good day graham...
my pagination is like this, <<-5-6-7->> and i want to make like this <<-5-6-7-8-9->>
here is my code:
# Paging function
function paging_template $url;$page;$active_page;$total_pages;
# Only one page so exit
if $total_pages == 1
return
endif
# Paging container
if $page == 1
print <nav class="pagination">
# First page button
if $page == $active_page
print <li class="disabled"><span>«</span></li>
elseif $page == 1
print <li><a href="$url">«</a></li>
endif
# Previous four pages buttons
if ($page+1) == $active_page or ($page+2) == $active_page
print <li><a href="$url">$page</a></li>
endif
# Current page button
if $page == $active_page
print <li class="active"><span><b>$page</b></span></li>
endif
# Next four pages buttons
if ($page-1) == $active_page or ($page-2) == $active_page
print <li><a href="$url">$page</a></li>
endif
# Last page button
if not $page == $total_pages
goto @skip
endif
if $page==$active_page
print <li class="disabled"><span>»</span></li></nav>
else
print <li><a href="$url">»</a></li></nav>
endif
@skip
endfunction