Reputation: 3042
I already have a limit 20. But how do I also limit the page numbers?
I'm trying to display the first 5 pages than have a ...[$lastpage]
So it would display like this:
1 2 3 4 5 ... 64
How would I do that? Thanks.
Upvotes: 1
Views: 140
Reputation: 11435
Use a counter when you loop through printing each page number....limit it to 5 or whatever number. Use an if statement to print only if the counter is >= 5 or the last page number.
Upvotes: 1
Reputation: 44776
Copy someone else's logic. For instance: http://d-scribe.de/webtools/jquery-pagination/demo/demo_options.htm
Upvotes: 2