WordPress开发者和主题制作者的搜索引擎



get_the_terms ›

Since3.1.0
已弃用n/a
apply_filters( 'get_the_terms', $terms, $post->ID, $taxonomy )
参数: (3)
  • (WP_Term[]|WP_Error) $terms Array of attached terms, or WP_Error on failure.
    Required: Yes
  • (int) $post_id Post ID.
    Required: Yes
  • (string) $taxonomy Name of the taxonomy.
    Required: Yes
定义在:
文档:

Filters the list of terms attached to the given post.





源码

$terms = apply_filters( 'get_the_terms', $terms, $post->ID, $taxonomy );