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:
  • (array|WP_Error)
Defined at:

Description

Adds a new term to the database if it does not already exist.

Related Functions

wp_create_user, wp_create_category, wp_create_tag, wpmu_create_user, wp_delete_term

Top Google Results

User discussions

wpseek mobile