terms_clauses

过滤钩子
apply_filters( 'terms_clauses', compact( $pieces )
参数
  • (string[]) $clauses { Associative array of the clauses for the query. @type string $fields The SELECT clause of the query. @type string $join The JOIN clause of the query. @type string $where The WHERE clause of the query. @type string $distinct The DISTINCT clause of the query. @type string $orderby The ORDER BY clause of the query. @type string $order The ORDER clause of the query. @type string $limits The LIMIT clause of the query. }
    Required:
  • (string[]) $taxonomies An array of taxonomy names.
    Required:
  • (array) $args An array of term query arguments.
    Required:
定义位置
相关勾子
sites_clausesnetworks_clauseslist_terms_exclusionscategory_css_classterm_name
相关方法
post_classget_post_classwp_terms_checklist_prime_term_cachesterm_existspostbox_classes
引入
3.1.0
弃用
-

terms_clauses – 这个过滤器允许开发者修改术语查询中使用的条款。terms_clauses过滤器适用于术语查询的子句,可用于修改查询的WHERE、ORDER BY、LIMIT和OFFSET子句。

过滤术语查询的SQL条款。

$clauses = apply_filters( 'terms_clauses', compact( $pieces ), $taxonomies, $args );

常见问题

FAQs
查看更多 >