Quantcast
Viewing all articles
Browse latest Browse all 31594

isaacalves on "Pagination link of custom post type goes to 404 error page"

Hello,

I created a custom post type ("works") and everything works well, but pagination links go to a 404 error page. And I also get this PHP error:

Trying to get property of non-object in (…)/wordpress/wp-includes/post-template.php on the line 29.

Why that happens?

Pagination in regular post type (for blog) works correctly.

Thanks in advance!

UPDATE:

It seems that it throws the error because there are no posts, which might as well be the same reason why the pagination link leads to an error page. Is that correct?


Viewing all articles
Browse latest Browse all 31594

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>