WP HOOKS
filtrreferencjaod 3.1.0

posts_clauses_request

Args 1Plik wp-includes/class-wp-query.phpDokumentacja WP ↗

Opis — z kodu źródłowego

Filters all query clauses at once, for convenience.

For use by caching plugins. Covers the WHERE, GROUP BY, JOIN, ORDER BY, DISTINCT, fields (SELECT), and LIMIT clauses.

Parametry

ParametrTypOpis
$clausesstring[]{ Associative array of the clauses for the query. @type string $where The WHERE clause of the query. @type string $groupby The GROUP BY clause of the query. @type string $join The JOIN clause of the query. @type string $orderby The ORDER BY clause of the query. @type string $distinct The DISTINCT clause of the query. @type string $fields The SELECT clause of the query. @type string $limits The LIMIT clause of the query. }
$query\WP_QueryThe WP_Query instance (passed by reference).

Wywołanie

Rejestracja callbackaphp
// rejestracja funkcji zwrotnej
add_filter( 'posts_clauses_request', 'twoja_funkcja' );

function twoja_funkcja($param_1) {
	// Twój kod
}

Popularne w tej kategorii