Questions tagged [pagination]

Pagination is the process of dividing information into discrete pages.

Pagination is the process of dividing information into discrete pages. Pagination is often used for the purpose of printing or searching information.

Pagination in Web content (HTML, ASP, PHP, and others)

On the Internet, pagination is used for such things as displaying a limited number of results on search engine results pages, or showing a limited number of posts when viewing a forum thread. Pagination is used in some form in almost every web application to divide returned data and display it on multiple pages. Pagination also includes the logic of preparing and displaying the links to the various pages.

Links

Wikipedia Pagination

17657 questions
39
votes
11 answers

UICollectionView: current index path for page control

I'm using a UICollectionView with a flow layout to show a list of cells, I also have a page control to indicate current page, but there seems to be no way to get current index path, I know I can get visible cells: UICollectionView current visible…
hzxu
  • 5,753
  • 11
  • 60
  • 95
39
votes
8 answers

Logic behind pagination like google

What is the logic behind google's pagination behaviour? My paginator goes something like this: [1] 2 3 ... 184 > < 1 [2] 3 4 ... 184 > < 1 2 [3] 4 5 ... 184 > < 1 2 3 [4] 5 6 ... 184 > < 1 ...…
ThomasK
  • 2,210
  • 3
  • 26
  • 35
38
votes
3 answers

Android Paging 3 - get list of data from PagingData object

I'm using new jetpack Paging 3 library. I have one specific use case. I want to share this data between two screens using viewmodel. One screen needs paged data and for the second screen I want simple list of this data (not paged list, I need to…
P.Dudik
  • 411
  • 1
  • 5
  • 4
38
votes
5 answers

Range query for MongoDB pagination

I want to implement pagination on top of a MongoDB. For my range query, I thought about using ObjectIDs: db.tweets.find({ _id: { $lt: maxID } }, { limit: 50 }) However, according to the docs, the structure of the ObjectID means that "ObjectId…
user1082754
37
votes
5 answers

Angular material Paginator is not working

I am trying to add Angular Material Paginator on my app. MatPaginatorModule added in module.
Umar Farooq Aslam
  • 485
  • 1
  • 8
  • 17
37
votes
11 answers

Simple pagination in javascript

I am trying to make pagination for my site. (http://anuntorhei.md) CODE: var someVar = 50; function someStupidFunction() { if (objJson.length > 50) { document.getElementById("nextPage").style.visibility = "visible"; …
tourniquet
  • 1,375
  • 2
  • 15
  • 19
37
votes
8 answers

Smart pagination algorithm

I'm looking for an example algorithm of smart pagination. By smart, what I mean is that I only want to show, for example, 2 adjacent pages to the current page, so instead of ending up with a ridiculously long page list, I truncate it. Here's a quick…
jeannicolas
  • 3,139
  • 4
  • 24
  • 25
36
votes
2 answers

Pagination with DynamoDBMapper Java AWS SDK

From the API docs dynamo db does support pagination for scan and query operations. The catch here is to set the ExclusiveStartIndex of current request to the value of the LastEvaluatedIndex of previous request to get next set (logical page) of…
Adi GuN
  • 1,244
  • 3
  • 16
  • 38
35
votes
6 answers

SQL Server query with pagination and count

I want to make a database query with pagination. So, I used a common-table expression and a ranked function to achieve this. Look at the example below. declare @table table (name varchar(30)); insert into @table values ('Jeanna Hackman'); insert…
Fabio
  • 3,020
  • 4
  • 39
  • 62
34
votes
3 answers

SQLAlchemy and going through a large result set

I need to read data from all of the rows of a large table, but I don't want to pull all of the data into memory at one time. Is there a SQLAlchemy function that will handle paging? That is, pull several rows into memory and then fetch more when…
Kevin Burke
  • 61,194
  • 76
  • 188
  • 305
34
votes
8 answers

How to use pagination in laravel 5?

am trying to port my laravel4 application to laravel 5 . In the previous version i could use the following method for generating pagination urls . In controller: $this->data['pages']= Page::whereIn('area_id',…
Sojan Jose
  • 3,168
  • 6
  • 33
  • 52
34
votes
4 answers

Update pagination in AngularJS after filtering

I already have the pagination implemented. Now I want the pagination to be updated after filtering my results. The form: The list:
  • Mischa
    • 1,073
    • 2
    • 13
    • 23
  • 34
    votes
    7 answers

    Best practice for pagination in Oracle?

    Problem: I need write stored procedure(s) that will return result set of a single page of rows and the number of total rows. Solution A: I create two stored procedures, one that returns a results set of a single page and another that returns a…
    Howie
    • 2,760
    • 6
    • 32
    • 60
    34
    votes
    5 answers

    Use of XSL-FO, CSS3 instead of CSS2 to create Paginated documents like PDF?

    There are a lot of old texts, like this 2002 book, stating that we must use "CSS for Web" and "XSL-FO for print". I think in nowadays (2012) we can, finally, to use CSS with render engines that understand paged media of CSS2 and something of CSS3...…
    Peter Krauss
    • 13,174
    • 24
    • 167
    • 304
    33
    votes
    3 answers

    Handle Paging with RxJava

    I'm using Retrofit + RxJava on an Android app and am asking myself about how to handle the API pagination to chain calls until all data is being retrieved. Is something like this: Observable getResults(@Query("page") int page); The…
    Rafael Toledo
    • 5,599
    • 6
    • 23
    • 33