Quantcast
Channel: Catalog Page – Build Your Own Business Website
Viewing all articles
Browse latest Browse all 10

How Pagination Works

$
0
0

We look at the WordPress pagination system and how the next and previous links work in order of pages. By default posts are displayed with the latest post first. Pagination appears to operate backwards with page 1 showing the most recent post, page 2 showing earlier posts and so on. You could set up your posts to go in reverse chronology so that your first posts are at the top and last posts are at the bottom but the problem with that is if someone wants to see your latest post they have to go to the bottom to find it.

[This post contains video, click to play]

Video Transcript

I have a related pagination question which comes in good play when you use one of the menu buttons to look at an entire query, I mean, entire category. Then again, what it was doing was it was paginating with the next and the previous at the bottom. But it was by default, sending you to the last page once it’s at every turn 3 pages. You were at the last page and you had to do previous and previous to get to the first page. That seemed odd to me.

Really? So here we are on the first page. If I select previous entries, it takes me to page number 2 and I select previous entries, it takes me to page number 3. That’s not what it’s doing for you?

Well, that’s what it’s doing but somehow that seems backwards to me. If you’re at page 1 and you want to look at page 2, you press previous. That’s counter-intuitive.

Well, that’s the way it works though. It’s always… yeah, it’s just…

Previous to 1? That completely doesn’t make sense.

Well, 2 isn’t previous to 1. It’s just that it’s displaying page 2 which shows the posts that are previous the posts that are on page 1. Because the way the posts work are is the newest is always on top. So the newest is always first so chronologically, it’s always going to go backwards even though pagination numbering seems to go forward.

Yeah, I see what you mean. It just seems a little bit busy to do it that way.

You know unfortunately, that’s just the way WordPress works. There’s no real way around that. If you wanted a way around that, what you’d have to do is you’d have to… you would really almost have to… I suppose you could do it in reverse chronology right? So that your first post is always at the top and your last post is always at the bottom. You certainly can do that.

Now the problem with doing that is if somebody wants to see your latest, they’ve got to go to the bottom which is why it works this way because the underlying assumption is people have already seen some of your stuff. So now what they want to do is they want to just see the latest stuff and so the latest stuff is the stuff that gets displayed. But I guess I understand why someone might not fully appreciate how that works. But the chances are, nobody but you is looking at this number right here. This number right here is completely transparent to them and all they think they’re saying is the next page.


Viewing all articles
Browse latest Browse all 10

Trending Articles