Filter hook 'date_query_valid_columns'

in WP Core File wp-includes/class-wp-date-query.php at line 510

Description

Filters the list of valid date query columns.

Occurrences

Filename Line Number
wp-includes/class-wp-date-query.php 510

Parameters

Type Name Description
string[] $valid_columns An array of valid date query columns. Defaults are 'post_date', 'post_date_gmt', 'post_modified', 'post_modified_gmt', 'comment_date', 'comment_date_gmt', 'user_registered', 'registered', 'last_updated'.

PHP Doc

/**
			 * Filters the list of valid date query columns.
			 *
			 * @since 3.7.0
			 * @since 4.1.0 Added 'user_registered' to the default recognized columns.
			 * @since 4.6.0 Added 'registered' and 'last_updated' to the default recognized columns.
			 *
			 * @param string[] $valid_columns An array of valid date query columns. Defaults
			 *                                are 'post_date', 'post_date_gmt', 'post_modified',
			 *                                'post_modified_gmt', 'comment_date', 'comment_date_gmt',
			 *                                'user_registered', 'registered', 'last_updated'.
			 */