In this specific case it is better to have some handling of bad configuration than trying to prevent it from happening, as there are just too many possible ways in which it can happen without coming from the post edit page. Short list that comes to my mind right now
- quick edit from the post list
- bulk update from the post list
- any plugin that may combine terms
- remote publishing via xml-rpc or the rest api
Blocking the save, especially for users that do not use the post edit screen, is going to end in bad UX as the user will not know why the save fails.
Related Posts:
- get_query_var() not working in pre_get_posts
- Creating a function that receives the taxonomy terms that have been changed in a custom post type
- In child theme, add CPT to custom taxonomy registered in parent theme
- Store a value in global scope after init hook is fired
- Changing CPT permalink
- Custom post types, taxonomies, and permalinks
- How to create a permalink structure with custom taxonomies and custom post types like base-name/parent-tax/child-tax/custom-post-type-name
- How to get all taxonomies of a post type?
- Permalinks: custom post type -> custom taxonomy -> post
- How do I query a custom post type with a custom taxonomy?
- How to Add Tags to Custom Post Type?
- Add category base to url in custom post type/taxonomy
- Include custom taxonomy term in search
- Custom Taxonomy specific to a Custom Post type
- List all posts in custom post type by taxonomy
- Mixing custom post type and taxonomy rewrite structures?
- Advanced search form with filters for custom taxonomies and custom fields
- Can multiple custom post types share a custom taxonomy?
- How to Add Custom Fields to a Custom Post Type?
- Hook for post and page load
- How to enqueue scripts on custom post add/edit pages?
- Remove taxonomy slug from a custom hierarchical taxonomy permalink
- Display all posts in a custom post type, grouped by a custom taxonomy
- How do you use a CPT as the default home page?
- Custom post type single-{custom}.php not working
- Remove Custom Taxonomy Metabox from Custom Post Type Screen
- Get terms by taxonomy AND post_type
- Theme localization of “slugs” (custom post types, taxonomies)
- Rewriting a custom-post-type permalink with taxonomy term?
- Saving Taxonomy Terms
- Get Posts by Custom Post Type ,Taxonomy, and Term
- Get The Post Type A Taxonomy Is Attached To
- Custom Taxonomy as checkbox or dropdown
- Getting custom taxonomy from custom post type
- Taxonomy: Why ‘with_front’ => false DOES NOT WORK?
- Shouldn’t this be easy?! Custom post type/custom taxonomy permalink
- Custom Post Type Permalink / Rewrite not working immediately
- How to Add Custom Taxonomy To Woocommerce Plugin
- How do I append multiple taxonomies to the URL?
- List all the tags from a custom post type
- Efficient Taxonomy Intersection
- How to get the posts of a custom taxonomy term
- WordPress Rewrite Rules for Custom Post Type and Taxonomy
- Show Custom Taxonomy Inside Custom Menu
- Display current taxonomy term when inside custom post type
- How to create a custom template for a custom taxonomy?
- Are custom post types lost when the theme is changed?
- Custom post types filtered by taxonomy using REST API v2
- limit selection of custom taxonomies to one?
- Calling a Function After New Post Creation for a WordPress Custom Post Type?
- Filtering a custom post type by custom taxonomy in archive template
- Permalink Structure for Multiple Post Type Archives by Taxonomy
- get term archive url / link
- Get term slug of current post
- What are the differences between custom post type and custom page templates?
- Custom Post type & Taxonomy URL structure
- Create a shortcode to display custom post types with a specific taxonomy
- Remove slug in taxonomy url
- List the categories under custom taxonomy
- Taxonomy, Terms, and Template Files
- How to pass URL parameters for advanced taxonomy queries with multiple terms for one custom taxonomy
- Custom Post Type and Taxonomy URL rewrite
- Any way to make posts inherit properties/taxonomies through a single assigned taxonomy
- Exclude a category from WP_Query
- Check if post type has term
- Custom Taxonomy as Dropdown in admin
- Combining Multiple Taxonomies in one URL
- get_the_category_list or get_the_tag_list for custom post types and taxonomies?
- Getting the Intersection of Two Custom Taxonomy Terms for a Custom Post Type?
- Why does my custom taxonomy show a total count across all post types
- How to Debug the ‘save_post’ Action?
- Set relationship between custom_post_types
- How to Make a Separate RSS Feed for Each Custom Post Type
- How can I rewrite URLs to pass taxonomy and post type values to the query?
- Custom Taxonomy’s Label to change the text appearing in Appearance > Menu
- Assign posts to taxonomy terms instead of the taxonomy terms to posts?
- Adding a drag and drop re-ordering from a custom post type default list [closed]
- How to completely disable a taxonomy archive on the frontend?
- $wp_query->queried_object->ID throws warning: Undefined property
- Automatically create child pages when saving a (parent) page
- Check if a custom taxonomy archive page is being displayed
- How to limit the number of terms (terms acts like categories)
- Permalink rewrite 404 conflict- WordPress Taxonomies/ CPT
- Get Custom Taxonomy ID within loop
- Custom Post Types not showing on Custom Taxonomy archive page
- WP insert post and custom taxonomy
- custom post type or taxonomy
- Pagination throws 404 error on custom taxonomy archive pages
- Create page to handle form submission
- How can I list all the categories under a Custom Post Type (taxonomy)?
- Select All in Parent Category, Group by Child Category?
- What should I use – Taxonomies, custom fields, Post Type?
- How do I Filter Custom Post Type by Custom Taxonomy in the newest WordPress RESTful API?
- Registering custom taxonomy with unique name, a good practise?
- custom post type and custom taxonomy permalink
- How to build a complex page structure
- wp_dropdown_categories in custom post type with custom taxonomy
- Ordering posts by custom taxonomy in admin area
- Custom Post type in separate database table for syncing
- Remove admin menu for custom taxonomy attached to custom post type