category_exists


category_exists ( $cat_name, $category_parent = null )

Parameters:
  • (int|string) cat_name Category name.
  • (int) category_parent Optional. ID of parent category.
See:
Returns:
  • (string|null) Returns the category ID as a numeric string if the pairing exists, null if not.
Defined at:

Description

Checks whether a category exists.

Related Functions

term_exists, tag_exists, wp_category_checklist, the_category_rss, get_category_parents

Top Google Results

User discussions

wpseek mobile