As you say, when triggered ‘save_post’ the changes are not been mae, so there’s not yet an association with a term.
But..in the $_POST['product_cat']
variable you have the array (IDS) of the selected categories, so you can check if the product belongs to the ‘Keyboard’ category ( based on its ID) and decide whether or not to perform further actions
Related Posts:
- How to get WooCommerce Product Category Link by ID?
- Hook to process a new taxonomy tag before it is created?
- Post Formats in the context of the Database ‘Save Post’ function
- How to assign default taxonomy to pages on ‘save_post’?
- Non-hierarchical custom taxonomy using checkboxes on edit-screen -> saving issue
- Approach for saving a product attribute values with a custom UI in a woocommerce+dokan set up [closed]
- Set download limit and expiry for WooCommerce downloadable products in specific categories
- Remove pagination from WooCommerce product categories on admin edit navigation menus
- Taxonomy , subtaxonomy,child taxonomy of a product woocommerce
- Woocommerce custom taxonomies page
- Outputting an array of term meta values in a custom WooCommerce tab?
- Programatically added attribute, set to ‘show on product page’ automatically. Woocommerce [closed]
- Get child product categories from parent product category in WooCommerce
- Top level parent taxonomy ID
- Woocommerce product search result layout page
- Filter WooCommerce admin products list by a custom taxonomy
- Woocommerce: How to change the add to cart text in a certain category? [closed]
- Catchable fatal error on custom category post
- Get custom category image from menu
- Hide product categories and taxonomy terms in menu if empty
- Display related products based on 2 specific product attributes values in WooCommerce
- How to target parent product category and its children using WooCommerce?
- woocommerce custom product category template
- Getting WooCommerce product related child categories
- Hiding taxonomies with no children WP_Query & tax_query
- How to display ACF taxonomy checkbox links on WooCommerce product category archive
- Hide custom Woocommerce taxonomies when empty
- Dynamically set taxonomy term and show admin notice on post save
- Add attribute taxonomy through code don’t appear in admin product page
- Update Post Taxonomy Automatically Based On Date
- unable to save custom taxonomy terms in a custom-built metabox in wp-admin
- Showing custom taxonomy in woocommerce signle product page
- Warning: Undefined variable $post in C:\xampp\htdocs\… after PHP upgrade
- Admin only taxonomies?
- Custom taxonomy only gets saved in quick edit
- Fill New Taxonomies
- Infinite Scroll appending Next Product Category Term pages
- How to exclude woocommerece product category in search results?
- Cloning product not copying custom taxonomies
- Check if any available product has specific attribute
- how to show product custom taxonomies in woocommerce rest api
- generate random slug when adding taxonomy
- WordPress search form and search result through ACF field in custom taxonomy
- Get user created Woocommerce attributes ( taxonomies ) [closed]
- Custom order of taxonomy using wp_get_object_terms and woocommerce_term_meta
- How do you search for a post by custom taxonomy?
- Display woocommerce product_cat child terms with thumbnails
- Woocommerce – how to get and display selected variations on single product page
- get_the_terms inside save_post gives old terms
- Taxonomy Child Not Updating Unless I Click Update Twice
- How do I check if a post has a term with a particular ancestor/parent?
- Creating a custom archive page for WooCommerce products based on tags
- Hide empty categories on widget
- Get the the top-level parent of a custom taxonomy term
- get_terms – only top level
- Order get_terms using a Custom Field
- How to modify the query in taxonomy-custom.php to sort term archives by a custom meta field?
- wp_options table value
- Custom Taxonomy Meta Admin Column
- Custom Taxonomy Only Showing Top Level Terms in Admin?
- wp_query orderby title and meta key value (WP3.1)
- custom taxonomies on permalink
- Landing in 404 Page on Navigating to Custom Taxonomy Archive
- Get main term from a sub term in Woocommerce
- Custom Taxonomy tree view not showing correctly in backend
- Generic taxonomy-term template page
- Category page for custom-taxonomy shows 404 when using custom permalink structure
- How to count the number of terms in a taxonomy
- Current category link filter
- Hook to change Custom Tag Taxonomy Links?
- Sorting Tags by Slug Value
- Search functionality in ‘taxonomy postbox’ on edit post page
- How to limit the number of users who can be added to a user custom taxonomy?
- Display only child terms of a specific parent term of a custom taxonomy, for each custom post
- Are exclusive taxonomy terms possible?
- Some custom taxonomy child terms not showing in admin. Caching problem?
- Custom Taxonomy Query
- Pass taxanomy parameters to next_post_link()?
- My custom taxonomy page is leading in 404 page
- List Top 5 taxonomy terms based on number of post
- Get list of taxonomies associated with users
- Taxonomy.php how to show post only in current taxonomy with wp_query?
- Include get_term_link inside search
- Tree view wp-admin terms
- Retrieve the child terms by having the parent’s information
- How to load terms of a custom taxonomy of a product in woocommerce cart page
- Is it possible to sort the post based on a custom field?
- Why get_terms() behaves strangely when being called in admin (for use in meta box)?
- qtranslate-x problem with custom term description
- Custom Tax Archive of Parents Only?
- ‘Post_tag’ taxonomy tags don’t link to existing posts in CMS
- Sorting terms individually for each post
- Looking for suggestions on creating simple database (Help!!)
- WordPress hiding posts without content on custom taxonomy query. How to solve?
- get meta fields and taxonomy of any post type
- Custom taxonomy – query returns an error
- Getting grandchildren of a post with a specified custom taxonomy?
- Taxonomy Parameters in WP Query to get posts from two different taxonomies
- Can you orderby slug in a taxonomy archive page using WP_Query?
- How to use wp_set_object_terms depending on page ID?