Setting The Navigation(Pagination) In SCJ

Post Reply
tubeman
Posts: 534
Joined: Sat Mar 02, 2013 11:33 am

Setting The Navigation(Pagination) In SCJ

Post by tubeman »

Hi,
When I insert the following code :

<ul class="pagination">
<li><a href="/search/<!--SEARCH_QUERY-->/ctr/1/" target="_self">Popular</a></li>
<li><a href="/search/<!--SEARCH_QUERY-->/date/1/" target="_self">Date</a></li>
<li><a href="/search/<!--SEARCH_QUERY-->/duration/1/" target="_self">Duration</a></li>
<navigation skip_href_deletion=false active_link_style=act_page link_style=not_act_page>
<li><a href="/search/<!--SEARCH_QUERY-->/<!--SORT_ORDER-->/<!--PAGE_NUM-->/" title="<!--PAGE_NUM-->" target="_self"><!--PAGE_NUM--></a></li>
</navigation>
</ul><!--/pagination-->

In The Navigation I Get

Popular - Date - Duration - 1 2 3 4 5 ... 43 44 45

However If I want the navigation to display

Popular - Date - Duration - 1 2 3 ... 43 44 45

How can I set it to only display the first 3 and last 3 pages with the scj dots in between? Basically instead of giving 8 links to pages on navigation I want only 6 links at any given time.

Any help would be appreciated.Thanks.
admin
Site Admin
Posts: 38004
Joined: Wed Sep 10, 2008 11:43 am

Re: Setting The Navigation(Pagination) In SCJ

Post by admin »

The only way to do it is draw navigation using your own script.

You have total amount of galleries and you know how many galleries per page so it's easy to calculate amount of pages and output it .
Don't forget to run script update
Post Reply