content
Tag cListPagination


Iterates through the list of paginated page numbers from the enclosing container list in the current range of pages.

The cListPagination tag doesn't display anything by itself. It loops over itself for every paginated page and executes other enclosed pagination tags. It must be enclosed within a container list.

Background: This tag is part of the Container List Pagination Tag set i.e. all content:cListPagination* tags. These tags facilitate displaying navigation widgets for paginated container lists, or what we refer to as Quick Page Access Buttons. These tags displays break up the a container list into a smaller sets (a.k.a. ranges/pagination windows) of pages. Below is an example generated menu :

<<Previous results  1  2  3  Next results>>


FYI here is its associated HTML code :

<a href="javascript:changePage(document.jahiapageform,document.jahiapageform.ctnscroll_directoryPeopleContainer,'5_0');"> \<\<Previous results</a>\ 
<a href="javascript:changePage(document.jahiapageform,document.jahiapageform.ctnscroll_directoryPeopleContainer,'5_0');"> 1</a>\  <b>
<a href="javascript:changePage(document.jahiapageform,document.jahiapageform.ctnscroll_directoryPeopleContainer,'5_5');"> 2</a>\  </b>
<a href="javascript:changePage(document.jahiapageform,document.jahiapageform.ctnscroll_directoryPeopleContainer,'5_10');"> 3</a>\ 
<a href="javascript:changePage(document.jahiapageform,document.jahiapageform.ctnscroll_directoryPeopleContainer,'5_10');"> Next results\>\></a> </p>

Example :

<content:jahiaPageForm name="jahiapageform">
<content:containerList name="directoryProjectContainer" title="Project container" windowSize="5">
     <content:cListPaginationCurrentPageScrollingValue valueOnly="false" />

<table border="0">
<tr>
     <td align="left" valign="top"><b>  Search : </b></td>
     <td valign="top" align="left">
         <input type="text" name="<content:ctnListSQueryInputName/>" value="<content:ctnListSQueryInputValue/>" size="30"/>  <a href="javascript:document.jahiapageform.submit()">Go</a>
     </td>
</tr>
<tr>
     <td align="left" valign="top"><b>  Filter by : </b></td>
     <td>
         <select name="directoryProjectCategory_filter" onChange="javascript:document.jahiapageform.submit()">
             <%
Enumeration projectCategoriesEnum= projectCategoriesVector.elements();
             while (projectCategoriesEnum.hasMoreElements()) {
String myCat = (String) projectCategoriesEnum.nextElement();
                 %><option value="<%=myCat%>" <% if (selProjectCategory.equals(myCat)){%>selected<% }%>><%=myCat%></option><%
             }
             %>
         </select>
     </td>
</tr>
<tr>
     <td align="left" valign="top"><b>  Result : </b></td>
     <td width="100%" align="left" valign="top">
         <table border="0" cellpadding="0" cellspacing="0">
         <tr>
             <td align="left" valign="top" nowrap>
                 <select class="text" name="directoryProjectContainer_windowsize" onChange="javascript:document.jahiapageform.submit()">
                 <option value="5" <% if (selProjectWindowSize.equals("5")){%>selected<% }%>>5</option>
                 <option value="10" <% if (selProjectWindowSize.equals("10")){%>selected<% }%>>10</option>
                 <option value="20" <% if (selProjectWindowSize.equals("20")){%>selected<% }%>>20</option>
                 </select> (Items/Page)   <font size="2">[<content:cListPaginationFirstItemIndex /> - <content:cListPaginationLastItemIndex />] of <content:cListPaginationTotalSize /></font>
             </td>
             <td align="right" valign="top" width="100%">
            
                 <content:previousWindowButton title="<<Prev" method="post" formName="jahiapageform" /> 
            
<b> <content:cListPagination nbStepPerPage="10" > </b>
            
                 <content:cListPaginationPreviousRangeOfPages method="post" formName="jahiapageform" title=" .. "/>
                 <content:ifCListPaginationCurrentPage>
                 <b>
                 </content:ifCListPaginationCurrentPage>
                 <content:cListPaginationPageUrl method="post" formName="jahiapageform" /> 
                 <content:ifCListPaginationCurrentPage>
                 </b>
                 </content:ifCListPaginationCurrentPage>
                 <content:cListPaginationNextRangeOfPages method="post" formName="jahiapageform" title=" .. "/>
                
                 </content:cListPagination>
                
                 <content:nextWindowButton title="Next>>" method="post" formName="jahiapageform" />
             </td>
         </tr>
         </table>
     </td>
</tr>
</table>

<input type="hidden" name="directoryProjectContainer_sort" value="<%=projectSort%>"/>
<input type="hidden" name="directoryProjectContainer_sort_order" value="<%=projectSortOrder%>"/>
</content:containerList>
</content:jahiaPageForm>


Tag Information
Tag Classorg.jahia.taglibs.pagination.CListPaginationTag
TagExtraInfo ClassNone
Body ContentJSP
Display NameNone

Attributes
NameRequiredRequest-timeTypeDescription
nbStepPerPagefalsetruejava.lang.Stringthe max number of Quick Page Access buttons to display at a time in the navigation bar.

In other words, this is the siye of the pagination window.

Default is -1 which displays all pages (i.e. the pagination window includes all pagination pages).

skipOnePageOnlyfalsetrueBooleanskip displaying pagination if there is only one page.

Set to "false" if you want to force displaying the Quick Page Access Buttons even though there is only one page available (and it is the currently displayed pages).

Default is 'true'.

namefalsetruejava.lang.String


Variables
No Variables Defined.


Output Generated by Tag Library Documentation Generator. Java, JSP, and JavaServer Pages are trademarks or registered trademarks of Sun Microsystems, Inc. in the US and other countries. Copyright 2002-4 Sun Microsystems, Inc. 4150 Network Circle Santa Clara, CA 95054, U.S.A. All Rights Reserved.