I've a category with actually 30 articles.
when switching from page 2 to 3 i got a 404 !
It's setyup for 10 articles per page. so at page 3 there are really items to display.
If I remove an article, page 3 goes well If I add an article, tot 31, page 3 works and also new page 4 works well
I cannot undeerstand what's the problem. And of course I need help to understand how to debug, I've no idea of internal routing strategy of wordpress, so I don't know which php file inspect ..
preguntado el 22 de mayo de 14 a las 14:05
I am not quite sure I understand the details, but in general: the way I would do it is change the URL scheme of WordPress and remove URL rewriting
(Set "ugly" links: http://codex.wordpress.org/Using_Permalinks )
Then go to your database and see if the pages you're trying to access actually exist (the table is called
wp-posts, compara el
id field to what you get in the GET variable
The code you're looking for is likely in the category.php file. Or at least that's the start of the codepath you should be digging through. If you're getting a 404, my guess is that the paging functions are not setting up the URL correctly. When looking through the links to different pages in this category, is one of them noticeably different (in structure) from the others?
This won't answer the OP's original pagination problem, but it might help someone with a 404 caused by something else. In my case, I had added a new taxonomy to a custom post type, and while I could see the archive page in development (actually
taxonomy.php was being called in the back-end), I was getting a 404 in production.
The fix was simple: I just needed to update the permalink settings. I didn't actually need to change them; I just needed to visit the permalink page and press "Save changes" at the bottom of the page. I think this regenerates something internally in WordPress. My taxonomy pages now show in production as they did in development.