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 |
|---|---|
| 3296 | * Splitting the query will cause it to fetch just the IDs of the found posts |
| 3297 | * (and then individually fetch each post by ID), rather than fetching every |
| 3298 | * complete row at once. One massive result vs. many small results. |
| 3299 | * |
| 3300 | * @since 3.4.0 |
| 3301 | * |
| 3302 | * @param bool $split_the_query Whether or not to split the query. |
| 3303 | * @param WP_Query $query The WP_Query instance. |
| 3304 | */ |
| 3305 | $split_the_query = apply_filters( 'split_the_query', $split_the_query, $this ); |
| 3306 | |
| 3307 | if ( $split_the_query ) { |
| 3308 | // First get the IDs and then fill in the objects. |
| 3309 | |
| 3310 | // Beginning of the string is on a new line to prevent leading whitespace. See https://core.trac.wordpress.org/ticket/56841. |
| 3311 | $this->request = |
| 3312 | "SELECT $found_rows $distinct {$wpdb->posts}.ID |
| 3313 | FROM {$wpdb->posts} $join |
| 3314 | WHERE 1=1 $where |