Filters the array of retrieved posts after they've been fetched and internally processed.
$posts\WP_Post[]$queryWP_Querywp-includes/class-wp-query.php:3633WP_Query::get_posts() * * @since 1.5.0 * * @param WP_Post[] $posts Array of post objects. * @param WP_Query $query The WP_Query instance (passed by reference). */ $this->posts = apply_filters_ref_array( 'the_posts', array( $this->posts, &$this ) ); } /* * Ensure that any posts added/modified via one of the filters above are * of the type WP_Post and are filtered. */Introduced in 1.5.0. Unchanged from 6.7.7 through 7.1.0.
Signature, return type and hooks compared across 5 parsed releases.