get_terms_orderby

get_terms_orderby

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: filter
See hook in action

See hook in core

Displaying hooks found in version: wordpress-6.7.2

apply_filters('get_terms_orderby') is found 1 times:

  • /wp-includes/class-wp-term-query.php line 954
    950
    951
    952
    953
    954
    955
    956
    957
    958
    959
    960
    * @param string   $orderby    `ORDERBY` clause of the terms query.
     * @param array    $args       An array of term query arguments.
     * @param string[] $taxonomies An array of taxonomy names.
     */
    $orderby = apply_filters( 'get_terms_orderby', $orderby, $this->query_vars, $this->query_vars['taxonomy'] );
     
    // Run after the 'get_terms_orderby' filter for backward compatibility.
    if ( $maybe_orderby_meta ) {
        $maybe_orderby_meta = $this->parse_orderby_meta( $_orderby );
        if ( $maybe_orderby_meta ) {
            $orderby = $maybe_orderby_meta;

See this hook used in plugins: