W3cubDocs

/WordPress

apply_filters( 'user_search_columns', string[] $search_columns, string $search, WP_User_Query $this )

Filters the columns to search in a WP_User_Query search.

Description

The default columns depend on the search term, and include ‘ID’, ‘user_login’, ‘user_email’, ‘user_url’, ‘user_nicename’, and ‘display_name’.

Parameters

$search_columns

(string[]) Array of column names to be searched.

$search

(string) Text being searched.

$this

(WP_User_Query) The current WP_User_Query instance.

Source

File: wp-includes/class-wp-user-query.php

View on Trac

Changelog

Version Description
3.6.0 Introduced.

© 2003–2019 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/hooks/user_search_columns