wp_unique_term_slug_is_bad_slug

过滤钩子


apply_filters( 'wp_unique_term_slug_is_bad_slug', $needs_suffix, $slug, $term )
参数
  • (bool)
    $needs_suffix
    Whether the slug needs to be made unique with a suffix.
    Required:
  • (string)
    $slug
    The slug.
    Required:
  • (object)
    $term
    Term object.
    Required:
定义位置
  • wp-includes/taxonomy.php
    , line 3054
引入
4.3.0
弃用

Filters whether the proposed unique term slug is bad.

if ( apply_filters( 'wp_unique_term_slug_is_bad_slug', $needs_suffix, $slug, $term ) ) {