You can use the pre_insert_term filter to do just this
https://developer.wordpress.org/reference/hooks/pre_insert_term/
Related Posts:
- Objective Best Practices for Plugin Development? [closed]
- How do i best handle custom plugin page actions?
- How to create an API for my plugin?
- Plugins in symlinked directories?
- In Which Contexts are Plugins Responsible for Data Validation/Sanitization?
- Plugin Form Submission Best Practice
- Best way to abort plugin in case of insufficient PHP version?
- What do you think about custom designed plugin/theme options UIs?
- Where to put third party PHP library?
- How to use PanelColorSettings in custom Gutenberg block?
- Optimize shortcode callbacks
- How to integrate a PHP webmail script into the backend of WordPress?
- Is There A Hook To Process The Content Of The Text Widget?
- How to log plugin errors to plugin error_log file
- Which to use to execute code during the saving of a plugin settings page?
- How can i list current author’s categories?
- How to Make a Category Always Selected?
- Custom theme sufficient or custom plugin neccessary for this feature set?
- When to check if a function exists
- How to create custom home page via plugin?
- Calling clean_term_cache() fails when called in the same plugin that creates terms, succeeds when called separately?
- Adding callback function for wp_ajax_ has no effect
- Sessions not creating correctly in custom function
- Featured Image not showing in admin
- How Can I setup WP CLI on Windows development machine running AMPPS?
- WP_LOCALIZE_SCRIPT doesn’t work
- Nuance in adding CPT and TAX to a submenu
- prevent post to have multiple categories in my plugin
- Can I differentiate between “Delete Post Permanently” and “Empty Trash” and do something for each accordingly?
- Get the password key when using the wp_new_user_notification_email filter
- How to deal with equal & similar arguments for a function?
- Which are the hooks run before/after when a category’s deletion?
- Customizer: widget-synced triggers twice
- Adding functions to hooks from within a class
- Disable The Events Calendar plugin from loading its scripts
- Applying OO patterns and principles to plugin development
- WordPress is automatically linking plain text email addresses
- Is Using WordPress Supplied WYSIWYG Advisable?
- Maximum lifetime for nonce
- Clearing caches on plugin uninstall
- Custom Taxonomy to dropdown box on adminside wordpress
- Create a free scripts and styles template within a plugin
- How to modify the comments to be displayed in a post?
- How can I turn a custom wordpress page into a product page?
- How to fetch products with the price in a page on woocommerce using a form or live search with php
- Incorporate small angular feature in my wordpress site
- How to Bind one post object Type with other postobject Type in Advanced Custom field [closed]
- How do I get the sub categories of the parent when in a sub category?
- Filter Categories widget to allow custom sorting?
- Enqueue script globally
- Redirect to another page using contact form 7? [closed]
- How should I go about registering JavaScript that isn’t a file? [duplicate]
- Custom entity search and display
- Plugin: database creation
- Loading Modernizr (or other JavaScript libraries) for use in a plugin
- Show message from backend
- Why in this archive page that call query_posts() function show only the last 10 posts?
- How can I show posts for a single category?
- How to display the categories on page using shortcode?
- Logout after clicking URL link results in “headers already sent” error
- How to display the category id along with category name on categories list?
- add_action pre_term_description vs. pre_category_description
- how to save wp_editor html content in options table
- Converting core modification to a plugin
- WP Dropdown Categories, display subcategories but not grandchildren categories?
- How to replace settings in WordPress plugin from a theme
- How to remove/replace current page template?
- Load stylesheet in edit category page?
- How to relate the Category to user?
- Setting a post’s category
- How to Show Category List With Corresponding Links?
- Serial Number from custom table not appear in woocommerce_email_before_order_table action
- Exclude Woocommerce Product Category From Sitemap
- How to show only the last two categories in a menu?
- How to create a custom post-new.php page for plugin , no wp menu
- Want to know how to reveal a WordPress theme, considering the theme name is hidden?
- How to check category name available or not
- Save meta box data from selected dropdown list in bbpress reply form
- Metabox types list
- Where to save Gutenberg plugin data?
- Hide post by ‘post_category’
- Yoast and another plugin
- Create Customization panel for Plugins not for theme
- external Integration with wordpress timeout error
- Add function to Dokan ajax class
- Making Woocommerce optimized for more than 500k products
- Add a new tag based on the category name in the publish event
- Implementing Select2 plugin into WordPress
- Managing Custom Designed Content
- Can I access WordPress API’s from within plugin scripts?
- Change the search results header from plugin
- Adding Meta box to thrid-party plugin
- Client Profiles
- Developing Themes on WordPress, Looking for Excellent Tutorials [closed]
- How to Implement SAM Broadcaster with WordPress? [closed]
- Extend WP_List_Table class – Edit wp_usermeta – WPPB.me Boilerplate – Action error
- Can I log the searches that are returning 404 in the DB?
- Developing an IP lookup function using an API
- Add File field in WooCommerce Box office plugin
- Custom Gutenberg Block ‘Stylized List’ – Incorrect Rendering and Looping of List Items