I always use something like:
add_action('save_post', 'mdz_correlate_casos_taxonomy');
function mdz_correlate_casos_taxonomy( $post_id ){
if ( defined('DOING_AUTOSAVE') && DOING_AUTOSAVE )
return $post_id;
if ( 'YOUR CUSTOM POST TYPE' == $_POST['post_type'] ){
if (!wp_is_post_revision($post_id)){
if (!term_exists( $_POST["post_title"], 'YOUR CUSTOM TAXONOMY' )){
$termid = wp_insert_term( $_POST["post_title"], 'YOUR CUSTOM TAXONOMY' );
}
}
}
}
But this is prone to get inconsistent (ie: if you delete a post, the term won’t get deleted)
Related Posts:
- Create a shortcode to display custom post types with a specific taxonomy
- List the categories under custom taxonomy
- Custom Post Type and Taxonomy URL rewrite
- How to build a complex page structure
- Taxonomy archive with same slug as custom post type?
- How can I convert a Custom Taxonomy to a Custom Post Type?
- Find callback function for custom taxonomy metabox
- Exclude a term of a taxonomy with a custom post type in a search
- Need some templating advice for templating with custom post types and taxonomies
- Custom Metabox with Taxonomy Dropdown – Saving Issue
- get terms that have post with custom post type between 2 values
- Page to display an archive of taxonomies
- How to make custom posts to behave like taxonomy?
- How do I provide a “show all posts” link in a paginated term archive?
- How to add a custom taxonomy to a custom post type’s document tab
- WP_Query search posts by custom post type and custom taxonomy
- get_queried_object error How to show post count by month in the taxonomy page
- List custom post type by custom tax term as page title
- Parent & Child Taxonomy slugs in custom post permalink
- Should I use custom taxonomy or custom post type
- get_posts of Custom Post Type AND Custom Taxonomy
- Custom Taxonomy Navigation, with current menu items for children?
- Custom Post Type doesn’t show Draft and Trash Options
- Custom Post Type With Categories
- A question on creating filters for custom posts using taxonomy
- Custom Taxonomy back-end customizations
- How can I made custom taxonomies relationship?
- How to start a new post with custom Taxonomies already set?
- How do I change the custom taxonomy slug to be the same as the custom post type slug?
- Custom Post Type by Taxonomy
- browse by category and tags?
- Taxonomy structure help
- Losing Nav Active State in Menu
- Different rewrite rules for taxonomies and cp in multisite?
- count results in search page based on custom category
- Assign Custom post to Custom Taxonomy
- Trick to get custom post types to show up on a custom taxonomy page?
- How to add custom taxonomy in custom post type permalink?
- Custom select query for taxonomies that have posts categorized in another taxonomy
- What’s the name of the custom post type yearly archive template?
- Combine multiple getEntityRecords calls
- Create an archive page for custom post type with custom taxonomy
- Custom URLs in post types make it impossible to view archive
- How to add and clear custom post types and taxonomies in a plugin? Considerations for existing data
- Custom Post Types Archives and Single Pages not showing custom taxonomy data
- How to setup a single post page for my custom post type?
- Dynamically insert code to custom post type loop
- Custom Taxonomy Search result page
- Permalink problems with custom post type and custom taxonomy
- Link From Single Post To Taxonomy Term Archive Page
- Pull in taxonomy field of custom post type in new query
- Use the custom post type archive for taxonomies?
- Custom Post Type Categories URL not displaying posts
- Custom order of Taxonomy Terms
- Taxonomy template page not working
- Custom post type subtaxonomy template
- tax_query (if the terms are empty)
- Getting only one post per category
- Issue with Custom Post Types and Single
- How to count other posts not having specific taxonomy terms?
- Calling related posts to a custom post type, taxonomy & Tag id
- List all posts in taxonomy term
- Looping through custom taxonomy and display custom post types (Custom Post Type UI)
- How to create subdomain for custom post type and associated custom taxonomies
- set post_type based on custom taxonomy permalink
- How can I tell if I’m on a custom post type archive page?
- Can’t Get Parent and Child Categories of Custom Taxonomy to Display
- Query for specific taxonomy that executes a particular loop depending on volume of posts?
- Create a Dropdown Selector and Redirect for a Custom Taxonomy in WordPress?
- How to Implement Search Functionality?
- Should I use a custom taxonomy or custom post type for grouping a list of panels associated with a group of tests?
- Why are custom taxonomies only appearing on the edit page of one of these types, but not the other?
- Search CPT by tag ids
- Custom post type 404 category page
- Post template with breadcrumb needs to show page navigated from
- How can i display a taxonomy? i have created a plugin and then a custom type. and a taxonomy , also i have register it
- How to associate custom taxonomy terms with custom post type?
- WP_Query not using custom taxonomy categories on custom post type
- Taxonomies are not showing in the category dropdown
- get_the_terms child terms for current post/custom post only
- Combine multiple separate lists into one
- Pages of my taxonomy terms are showing all posts
- Is there a way to re-order the Custom Taxonomy drop-down on a Custom Post listing page?
- Custom taxonomy- only output relevant terms
- Post types showing tables…Can I do that?
- Post Custom & Taxonomy 404 error
- Custom Post Type tag taxonomy “Page Not Found”
- Remove custom post type slug but keep related category taxonomy permalink
- page not found for example.com/custom-post-name
- Dropdown switching subcategories portfolio
- Is it possible to add and display custom post types to an array?
- Custom post type and custom taxonomies display
- Displaying posts exclusively in their category (not parent)
- predefined custom field on registration page
- Timetable of Custom Meta Data using Custom Post Type and Custom Taxonomy
- Adding rewrite rules to Custom Post-type mixed with Taxonomy
- Tags and Taxonomy links not working for Custom Post Types
- Inserting two categories
- How to manage a bookstore
- Permalinks for Custom Post Types and Taxonomies