sync_category_tag_slugs


sync_category_tag_slugs ( $term, $taxonomy )

Parameters:
  • (WP_Term|array) $term The term.
  • (string) $taxonomy The taxonomy for `$term`. Should be 'category' or 'post_tag', as these are the only taxonomies which are processed by this function; anything else will be returned untouched.
Returns:
  • (WP_Term|array) Returns `$term`, after filtering the 'slug' field with `sanitize_title()` if `$taxonomy` is 'category' or 'post_tag'.
Defined at:

Description

Synchronizes category and post tag slugs when global terms are enabled.

Related Functions

get_category_by_slug, the_category_rss, is_category, in_category, category_exists

Top Google Results

User discussions

wpseek mobile