A
A
Anton Parkhomenko2020-02-10 16:21:08
MODX
Anton Parkhomenko, 2020-02-10 16:21:08

How to make page navigation for resources?

Good day to all.
There are two sites: one on Wordpress, the other on Modx Revo. But they have the same problem:
Please tell me how to properly implement pagination for resources?
How it is done now for me: in the category template, I wrote "page.nav". Navigation on the category page works. And if you specify page.nav in the resource itself, then it does not work.
Therefore, the WP-PageNavi plugin does not work on WP either.
What I want to get as a result:
To make navigation on the material page (blog post) work without leaving the category page. So that the user simply navigates through full-text resources within the same category.

Category 1
...Page 1
...Page 2
...Page 3
...Page 4
That's just "page.nav" does not work on pages.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
D
Dmitry, 2020-02-10
@i__dmitry

The page.nav placeholder cannot work on a post page because it only works when a collection of posts is rendered via pdoPage. If there is no pdoPage call on the page, there will simply be no placeholder.
But here the question is different: what exactly do you want to achieve by placing pagination on the post page? Where will the links to the page numbers go?

I
Igor, 2020-02-20
@ig0r74

To display links to the previous/next resource:
https://docs.modx.pro/komponentyi/pdotools/snippet...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question