Found the answer:
After a looong day debugging thru wordpress core, I managed to solve
this issue.Basicly, you CANT have a PAGE and a CUSTOM POST TYPE with the same
name. If you do, the permalink rewrite rules will get confused and
trigger a 404.A very simple solution I’m using is: The page that lists the custom
post types is called in plural (eg. products) and the actual post type
name is in singular (eg. product). So they dont conflict and it’s all
fine.Done Done! Hope this will save people’s time.
Related Posts:
- Passing and retrieving query vars in wordpress
- Get the current page URL (including pagination)
- Get current URL (permalink) without /page/{pagenum}/
- Why does `get_permalink()` produces an add. DB request without $post->filter?
- Date based URLs for custom posts and pagination
- Adding anchor to paginate_links + Safari anchor bug
- Custom permalink with pagination
- 404 on category.php pagination
- Add ‘articles’ prefix before blog posts url without affecting pagination
- Clean install – Changing permalinks in twentyeleven give 404
- Custom permalink for search and pagination
- wp_logout_url redirects to incorrect page because of pagination
- How to Get Page 2 / Paginated RSS Feed with Custom Permalink Structure?
- Pagination Issue – /page/2 404
- next_posts_link URL does not include name of custom post type
- Why is page/2/ not working?
- Pagination for blog posts reloading same page [closed]
- How to handle paging/pagination with a custom permalink?
- Change permalink structure for pagination only
- Pagination using paginate_links
- Home page Pagination – Other pages do not redirect to home page template
- Pagination url for page template
- problem with pagination in custom permalinks
- Whole site’s pagination not working after rewriting product permalink
- WordPress /page/2 gives 404 when custom permalinks is set to %category%%postname%
- How to get a clean pagination link without variable
- Added .html to Woocommerce permalink but pagination don’t work!
- Pagination links for taxonomy archive page 404 error on every page except first
- WordPress Pagination Not Working After Transfer from Localhost
- Add Custom Pagination Permalink
- Search page Paginations not working
- Pagination is not working, how to trace it properly?
- How to change pagination base from slash to query form?
- Category pagination first link works, remaining don’t
- Why doesn’t my page know it’s a page (won’t return true for is_page())?
- Getting the terms from “Beautiful Taxonomy Filters” Results ot Integrate into “Ajax Load More”
- Post archive pages bringing me to a 404 page
- WP Category Archive /page/2+ pagination issue 404
- Is it possible to get a page link from its slug?
- Need help with add_rewrite_rule
- Pagination when using wp_query?
- After server migration only the homepage works
- How can i retrieve default post per page value? from settings->reading. And total number of posts?
- remove “index.php” from permalinks
- Find out total number of pages in global query on archive page?
- where is permalink info stored in database?
- Changing permalinks gives me 404 errors on nginx
- How do I add /blog/ as a prefix to permalink structure for blog posts, tag pages, etc.?
- Post_count only shows the number of results per page
- Change media item permalink
- Get Permalink without domain (i.e. get relative permalink) [duplicate]
- How does WordPress create URLs that Apache knows about?
- Strange permalink issue: can’t rename /company-2/ to /company/
- Stop WordPress appending `-2` to the end of my url after i change it
- Get default permalink structure from pretty URL’s
- How to get permalink and title from post ID?
- WordPress Permalinks not working in Apache2 Ubuntu 14.04
- Performance of my permalink structure?
- Permalink format: singular or plural
- Multiple WP_Query loops with Pagination
- What is the difference between get_post_permalink and get_permalink?
- WordPress matching URLs with trailing tildes
- Pagination with custom SQL query
- How does WordPress handle permalinks?
- Pretty permalinks for search results with extra query var
- Get page permalink without wpurl
- How can I get the privacy policy page?
- Can I use REST-API on plain permalink format?
- WordPress Pagination Not Working – Always Showing First Pages Content
- WordPress slug issue with non-latin characters
- Rewrite Rule for Multilingual Website, Like qTranslate?
- How to get pretty URLs with add_query_arg in permalinks
- What is the best permalink structure for SEO?
- Change author permalink
- Creating custom permalink structure for languages
- Hide permalink and preview button and link on custom post
- Custom post type permalink endpoint
- How can I make Capital letter ( upper-case ) permalinks?
- The next_posts_link() works only with original $wp_query
- How can I reverse engineer a Permalink to Find the Page?
- Mapping Domains to Permalinks (not multisite)
- How to remove dates from existing permalinks?
- How do I set a custom base URL for standard posts?
- Removing Parent Page(s) from Permalink
- Why permalinks work with /index.php/%postname% but not with just %postname%?
- get_query_var function not working at all
- Setting up WordPress with Custom Permalinks and no .htaccess File?
- Getting the Site URL Including the Front Base
- Does WordPress Change the .htaccess File When Updating?
- get_query_var( ‘paged’ ) not working outside of homepage
- Using $_GET variables in the URL?
- Removing the redirect after changing a page’s slug
- How to display a public profile page for registered users with custom slug?
- Removing leading zeros from custom permalink structure
- Must slugs be unique?
- Setting 404 page in Nginx
- How to get the clean permalink in a draft?
- Pagination on a WP_query not showing navigation links
- How to use relative links on my pages?
- How does wordpress keep track of post id when post id is not used in permalinks?