Currently there is no way on the backend (UI) for unregistering a post type, the
process however is quite simple.
Andrew Nacin provided some code over on https://core.trac.wordpress.org/ticket/14761
You can easily create a plugin with this function and have the CPT unregister.
if ( ! function_exists( 'unregister_post_type' ) ) :
function unregister_post_type( $post_type ) {
global $wp_post_types;
if ( isset( $wp_post_types[ $post_type ] ) ) {
unset( $wp_post_types[ $post_type ] );
return true;
}
return false;
}
endif;
Related Posts:
- What does this PHP function code mean? [closed]
- Restrict custom post type to only site administrator role
- Linking Two Post Types
- How to force one column layout on custom post type edit page?
- modify all posts of a category to “no comments allowed”
- Why is the »_builtin« parameter not advised in »register_post_type()« for custom post types?
- Showing current taxonomy terms
- automatically create taxonomy with same name as post title
- Assigning a role to a specific custom post type (and ignoring other post types)
- Display posts in random post types
- Custom Post Type by user
- saving custom post type data to different table in wordpress
- Query post types with multiple keys
- [Plugin: Posts 2 Posts] Changing display order of connections
- Remove POST_TYPE from custom post type permalink
- same archive template for different custom post
- Get all posts WHERE custom_field is LIKE value
- Get the post children count of a post
- How to delete all posts from a custom post type?
- Best practice for adding posts in bulk
- Check Title Unique Or Not and If not error message and dont save
- Remove All, Published and Trashed Post Views in Custom Post Type
- Custom Post Type | Fatal Error on register_post_type()
- How to post twitter like updates on wordpress
- Show Two custom Post type and their posts on category page
- apply filters only to specific post listing without check the url parameters
- Custom post type and body_class: Remove “blog” class
- Deleting Custom Post type data using mySQL command
- Is there a way to have the view link on manage posts page to open in a new window or tab?
- If post has custom field then display css-class
- Display only one post each WEEK
- List custom taxonomy specific to one custom post type
- Meta query for custom post type ignored in main query
- Show titles, date of all posts on single category page
- Update postmeta Parent when post_status child change
- How to Get WordPress custom post data in WooCommerce product meta panel? [closed]
- Allow users to create posts without logging in?
- How to sort posts in a custom post type by title in ascending order by default?
- Redirect to another page using contact form 7? [closed]
- How can I have different content for different countries?
- Get_the_terms restrict output
- Custom post type menu
- Custom post type’s posts are not showing anywere but in xml sitemap
- YOAST SEO won’t work on custom post type archive [closed]
- Separate Content from gallery (custom post type)
- Modify Posts from Custom_Post_Type within the plugin
- WordPress Count posts within a custom post type
- Add custom columns in custom post type browse page
- Send post changes to set email addresses (not users or subscribers)
- Custom post type tags not showing in search
- How set template for “custom post type” individual post
- Why is my custom post content only viewable when signed into WordPress?
- Adding specific custom fields (images) to post excerpt
- Add input radio menu to post
- Limit posts per page depending on the size of a div?
- Delete Post by User
- Link two different post using there post_id in post meta
- Post that populates itself (almost) automatically using data from imported excel file
- creating a custom post template
- Problem to get the link of the default ‘post’ post type like the orther custom types
- How to display all custom fields associated with a post type – IN THE ADMIN AREA?
- One Post with different content, depending on a Page
- Custom Post Type
- Display all post types together
- Add Excerpt On Quicksand Plugin
- Turn post into simple slideshow
- Query multiple post of which one by taxonomy
- How to make a template for a specific post of a custom post type?
- How to hide home title on pages and posts?
- How to create a job post by email parsing? [closed]
- show posts under custom post type with same autj
- How to automate the creation of advanced layout article/post
- display posts, pages and custom post types from another wordpress site
- is therer any wordpress function to retrieve a specific html element from post content
- How to develop Knowledge center in WordPress Website
- ACF – Tags not showing up in Custom Post Types
- Admin Post Update Redirection to Posts Screen
- Single Page WordPress CSS and JS links
- Disable dragging of metaboxes in custom post types?
- Structure for projects and clients
- “add_post_type_support” with Custom Post Type & ACF
- Group posts by custom post type
- Adding a custom post type taxonomy template in plugin
- Plugin: register custom post types, child ready and performance best practices
- Check post on publish for blank title
- Different Limit number of post on different archive page
- Dynamic pages for linked categories and content
- Create Custom Post type that uses Page.php template
- Displaying a custom post type using get_template_part into a specific layout
- How can I make custom static widgets/areas on my homepage?
- Setting Parent Page to Post
- Custom Post Type and Structure Question
- pricefilter without WooCommerce
- Update/publish custom post type with jQuery?
- cannot export data from CPT UI (books)
- REQUIRED: The theme uses the register_post_type() function, which is plugin-territory
- WP 4.4 upgrade custom post type cannot add new
- Drawbacks of making the default post-type: post hierarchical [closed]
- Default post showing more than intended
- How to show custom post type in all post section?