wp_create_term
wp_create_term ( $tag_name, $taxonomy = 'post_tag' )
Parameters:- (string) tag_name The term name.
- (string) taxonomy Optional. The taxonomy within which to create the term. Default 'post_tag'.
Returns:Defined at: - Introduced in WordPress: 2.8.0
- Deprecated in WordPress: —
Description
Adds a new term to the database if it does not already exist.