rest_{$this->post_type}_query

Advertisement

Summery Summery

Filters the query arguments for a request.

Syntax Syntax

apply_filters( "rest_{$this->post_type}_query", array $args, WP_REST_Request $request )

Description Description

Enables adding extra arguments or setting defaults for a post collection request.

Parameters Parameters

$args

Key value array of query var to query value.

$request

The request used.

Source Source

File: wp-includes/rest-api/endpoints/class-wp-rest-posts-controller.php

Advertisement

Changelog Changelog

Changelog
Version Description
4.7.0 Introduced.

Advertisement

Leave a Reply