wood burning stoves
The moose likes HTML, CSS and JavaScript and the fly likes Pagination style Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of OCA Java SE 8 Programmer I Study Guide this week in the OCAJP 8 forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Pagination style" Watch "Pagination style" New topic

Pagination style

venkata swamymora
Ranch Hand

Joined: Aug 06, 2007
Posts: 33
I want a javascript code for pagination (or) navigate the records which is retrived from the database

my target shown below:

< << 1|2|3|4|5 >> >

Please help me regarding this

Patricia Samuel
Ranch Hand

Joined: Sep 12, 2007
Posts: 300
You have to use rownum in your query that will fetch records like this
rownum>=lowerlimit and rownum<=upperlimit

just calculate lowerlimit = (pageno-1)*no_of_records_per_page
and upperlimit = pageno * no of records_per_page;
where no_of_records_per page is the number of recoreds you wish to show on a page.

send selected pageno <1|2|3> to action.

See if it helps .

Ulf Dittmer

Joined: Mar 22, 2005
Posts: 42958
You might also want to read http://faq.javaranch.com/java/PaginationOrPaging
I agree. Here's the link: http://aspose.com/file-tools
subject: Pagination style
It's not a secret anymore!