WP hooks navigation: Home/browse • Actions index • Filters index
To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).
The best way to understand what a hook does is to look at where it occurs in the source code.
do_action( "hook_name" )apply_filters( "hook_name", "what_to_filter" ).Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.
| Line | Code |
|---|---|
| 1370 | /** |
| 1371 | * Filter the ORDERBY clause of the terms query. |
| 1372 | * |
| 1373 | * @since 2.8.0 |
| 1374 | * |
| 1375 | * @param string $orderby ORDERBY clause of the terms query. |
| 1376 | * @param array $args An array of terms query arguments. |
| 1377 | * @param string|array $taxonomies A taxonomy or array of taxonomies. |
| 1378 | */ |
| 1379 | $orderby = apply_filters( 'get_terms_orderby', $orderby, $args, $taxonomies ); |
| 1380 | |
| 1381 | $order = strtoupper( $args['order'] ); |
| 1382 | if ( ! empty( $orderby ) ) { |
| 1383 | $orderby = "ORDER BY $orderby"; |
| 1384 | } else { |
| 1385 | $order = ''; |
| 1386 | } |
| 1387 | |
| 1388 | if ( '' !== $order && ! in_array( $order, array( 'ASC', 'DESC' ) ) ) { |