If we look at the register_post_type
documentation, in the rewrite option, there is a sub-option that controls this:
'with_front'
=>bool
Should the permalink structure be prepended with the front base. (example: if your permalink structure is /blog/, then your links will be: false->/news/, true->/blog/news/). Defaults to true
So something like this:
...
'rewrite' => [ 'with_front' => false ],
...
Related Posts:
- Custom Post Type “MUST NOT” be able to search via URL
- Permalinks for Custom Post Types and Taxonomies
- Permalinks: custom post type -> custom taxonomy -> post
- Custom post type archive pagination 404
- CPT’s with landing page instead of archive – Url Rewrite?
- Include related custom fields from one post type in another post type’s JSON feed
- How to change permalink to include custom post type
- Removing Custom Permalink Structure for Custom Post Type
- Custom post type, permalinks, taxonomies and blog posts
- How to give all CPT a folder automatically based on their slug
- Custom post type permalink tag 404
- Custom post type permalink returns 404
- Use the same date-based permalink structure for all post types
- Permalink structure with custom taxonomies and custom post type like /parent-tax/child-tax/custom-post-type-name (with no base name)
- permalink /category/post-name with custom post type and taxonomy
- Define/declare new custom types with fields in plugin?
- “Post name” permalink returns home page for custom posts
- Custom post type and taxonomy permalinks
- Hierarchical permalinks for custom post type and taxonomy
- How to organize hierarchical structure in custom post type with taxonomy (like with categories)
- Make custom post types and pages place nice, re: rewrite
- Custom Post Fields at the beginning of a Custom Permalink
- Flush Rewrite Rules when new site is created on network
- Pretty URLs and custom post types
- Form action doesn’t work if slug isn’t same as custom post title
- How to make permalink structure %category%/%postname%/ work for custom post type?
- set permalink for CPT
- How to get a custom field value of a custom post?
- Ignoring slug capitalization on rewrite rule for custom post type archive page
- Lost of query parameter when using permalink
- Custom permalinks rules don’t match and lost of query var in the process
- Custom Post Type – Duplicate Page Slugs
- How to produce a sub-page-system in WordPress
- Rewrite rule for Custom post type Monthly and Yearly archive
- Different results between permalink and query var search
- menu link to custom post_type?
- Custom permalink with child taxonomy terms
- Custom post type Permalinks with hierarchical Taxonomies
- 404 in custom post type feed with mistake permalink
- Add a permalink variable onto custom post type URL after post name slug
- Remove permalink for custom post type
- Permalink misbehaving in Custom Post Types
- Check post on publish for blank title
- How to solve this custom post type goes to 404 page?
- Best way to specify “article type” in URL
- Template files for Custom Post Type and Taxonomy
- How to Create Template File for Parent Page of Custom Post Type
- How do you create %post_type%/%postname%/ permalink structure?
- Problems with 404, .htaccess, permalinks and WordPress custom posts locally on Snow Leopard
- Changed permalink structure of CPT – should I redirect?
- How to query 2 custom post types that need to share a slug?
- I’m having trouble getting the permalink sample on my custom post type edit page to work
- How to change path for default WordPress blog posts?
- How do I create an overview page with custom calculations from a post-type?
- How to hyperlink content from archive page with custom post-type
- Can’t use pagination with custom taxonomy
- retrieve permalinks of posts inside custom post type by using post ID
- Custom Permalinks with meta value not working. Why?
- Custom post type as child of page
- Remove custom permalink structure from custom post type without modifying register_post_type() directly
- How to group navigation items in the admin panel
- How to have permalink like domain.com/term/postname?
- Can variables be used to rewrite a Custom Post Type permalink? [duplicate]
- make permalink go to a custom single.php file
- Pods CMS: How to add custom column to Adnvanced Content Type
- Custom post type permalink sends to 404.php
- Post will not load via ajax
- Template for custom post type when taxonomy is in the URL
- One Custom post type 404’s others don’t
- Custom Post Type posts, conflict with posts after add_rewrite_rule to top
- How to change base in tag URL for custom post type, to not use “Custom Structure” set in Permalinks setting?
- Combine multiple CPT names to create valid permalinks
- Permalink problems with custom post type and custom taxonomy
- How to implement a different permalink structure for custom post type?
- WordPress different templates for same type custom post (but different slug)
- Set parent for custom post type archive rewrite url
- How to rewrite the beginning and end of the permalink structure in a custom post type?
- Route subpage to Custom Post Type
- Custom post type permalink returns 404 when set to private
- Post URL based on Custom Post Types variables
- Custom Post Type Advanced Slug
- Dynamic CPT permalink structure based on ACF field value
- Custom post type slug 404
- Custom permalink not working and showing 404 page not error
- Custom Post Type permalink without /%day%/ and/or /%postname%/
- How to filter a custom post type by custom taxonomy without 404
- How to get all posts related to particular category name on button click?
- how to retain the ability to modify the post slug after applying a post_type_link filter?
- Rewrite permalink for multiple post types (CPT) with taxonomy term
- Post type Permalink
- get the permalink never return with empty value
- Custom Post Type to replace Woocommerce products – page not found error
- WordPress custom permalink and archive link for custom post type
- Ideas on how to organize a project [closed]
- Redirect User From Registration Page To CPT (profile page) with custom url
- Custom Post Type Archive template not being called
- Custom Post Type with Configurable Sidebar via ACF
- Custom Post Types,Permalink and Heirarchy
- Pagination of custom post type leads to 404 error
- Custom Post Type with modified permalink structure results in 404