хук-фильтр
since 2.1.0
posts_distinct
Проверено на WordPress 6.9, обновлено Источник: WordPress Developer Resources.
Сигнатура
apply_filters_ref_array( 'posts_distinct', string $distinct, WP_Query $query )
Описание
Фильтрует секцию DISTINCT запроса.
Фильтруемое значение
Секция DISTINCT запроса.
Параметры
$distinct
string
обязательный
Секция DISTINCT запроса.
$query
WP_Query
обязательный
Экземпляр WP_Query (передаётся по ссылке).
Исходный код
wp-includes/class-wp-query.php:2973
$distinct = apply_filters_ref_array( 'posts_distinct', array( $distinct, &$this ) );
История изменений
| Версия | Описание |
|---|---|
| 2.1.0 | Introduced. |

