MediaWiki  1.34.0
UserNamePrefixSearch Class Reference

Handles searching prefixes of user names. More...

Static Public Member Functions

static search ( $audience, $search, $limit, $offset=0)
 Do a prefix search of user names and return a list of matching user names. More...
 

Detailed Description

Handles searching prefixes of user names.

Since
1.27

Definition at line 30 of file UserNamePrefixSearch.php.

Member Function Documentation

◆ search()

static UserNamePrefixSearch::search (   $audience,
  $search,
  $limit,
  $offset = 0 
)
static

Do a prefix search of user names and return a list of matching user names.

Parameters
string | User$audienceThe string 'public' or a user object to show the search for
string$search
int$limit
int$offsetHow many results to offset from the beginning
Returns
array Array of strings

Definition at line 41 of file UserNamePrefixSearch.php.

References $dbr, $res, DB_REPLICA, User\newFromName(), and wfGetDB().

Referenced by SpecialListFiles\prefixSearchSubpages(), SpecialUnblock\prefixSearchSubpages(), SpecialNuke\prefixSearchSubpages(), SpecialRenameuser\prefixSearchSubpages(), SpecialEmailUser\prefixSearchSubpages(), SpecialContributions\prefixSearchSubpages(), UserrightsPage\prefixSearchSubpages(), and SpecialBlock\prefixSearchSubpages().


The documentation for this class was generated from the following file: