Archived topic
Pagination with "/"
5 replies · Started by Renaud on May 19, 2019
hi,
On my site, when I navigate within a category that includes several blog articles in list mode, the pagination of the category (link from page 2 to page 1) refers to https://lebonrhum.fr/category/les-rhums/ instead of https://lebonrhum.fr/category/les-rhums generating canonized urls for me.
How do I delete the "/" at the end of the url in my pagination?
Hi there,
This might help: https://moz.com/community/q/how-to-force-wordpress-to-remove-trailing-slashes
Let me know :)
I apologize for my English, maybe I misspoke.
All my categories are already accessible without "/". Only the links in the category pagination (next/prev) use "/" which generate unnecessary 301 redirections to the version of the url without "/".
I'm not sure adding a redirection rule at the htaccess level solves this problem because the redirections are already done. I would like to fix the origin of the problem;). What do you think about that?
No worries - we'll get there :)
So when I go to the second page, I see this: https://lebonrhum.fr/category/les-rhums/page/2
Is that not correct?
When I browse pages like:
https://lebonrhum.fr/category/les-rhums/page/2
or
https://lebonrhum.fr/author/titomus/page/2
Links in the pagination, at the bottom left like "<-Précédent" or "1"
point to:
https://lebonrhum.fr/category/les-rhums/
and
https://lebonrhum.fr/author/titomus/
instead of :
https://lebonrhum.fr/category/les-rhums
and
https://lebonrhum.fr/author/titomus
Is it more clear ?
Ah, it looks like a bug in WordPress itself that hasn't been fixed yet: https://core.trac.wordpress.org/ticket/43789