PHP pagination range
I've tried using Google and other sources but I can't find an answer. I have even looked at other's coding and still don't understand. I'm wanting to create a pagination (success) but when displaying the links, I want to be able to add a range. For example: 123...789...13 14 15 and so on. So it skips a few links until near the number.
Could someone explain how to do this?
Thank you.
For doing this in a general way that allows a user to rapidly reach any page in the entire range, consider using "logarithmic pagination" as described in my answer here:
How to do page navigation for many, many pages? Logarithmic page navigation
PHP code is included, and it'll do everything your question requests.
精彩评论