The moose likes Struts and the fly likes Page Breaks... Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Page Breaks..." Watch "Page Breaks..." New topic

Page Breaks...

s mahen perera
Ranch Hand

Joined: Mar 08, 2005
Posts: 101
Hi all,

Not sure whether this is the correct forum to ask this Question,, anyway..This is my problem.
I have list of items to be displayed in a Web page, and the number of items displayed per page is configurable by the user thru a select box in the web page it self, (eg : the options in the Select box can be something like ; 10 results per page, 20 results per page, 50 results per page etc), where the user can select any option from the select box and the page must refresh and show the results accordingly.

apart from this , there must be links for Previou Page and Next Page in each page, so that the user can browse to the previous list of the next list of the items.
and also there must be links for each page where the results are displayed,
(like pages 1 2 3 ..., where each of these page numbers when clicked will go to the corresponding list of items )

is there anything from Struts that i can use in order to do this feature easilly? or else any JSTL tag? or else any Open Source tag ? or else should i write my own Custom tag? ...

thanks in advance for any help
Arulanand Dayalan
Ranch Hand

Joined: Aug 10, 2005
Posts: 124
You can use Display Tag for doing it or write a java code for implementing paging logic. For eg. u look in this website
s mahen perera
Ranch Hand

Joined: Mar 08, 2005
Posts: 101
Thanks Arulanand for the info
I agree. Here's the link:
subject: Page Breaks...
It's not a secret anymore!