Closed (outdated)
Project:
Masquerade
Version:
7.x-1.x-dev
Component:
User interface
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
21 Mar 2013 at 20:40 UTC
Updated:
17 Apr 2026 at 11:15 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
maxplus commentedYes,
that would be cool for me too.
Now I think the current search is looking only to the first word of the username
Comment #2
leendertdb commentedI have added a patch which changes the SQL query to search on both the username and the email address as full wildcards (%string%), instead of only searching on the beginning of the username (string%).
In our usecase usernames are automatically generated based on the email address the customer enters, so it makes more sense to search on both usernames and email addresses.
I don't think making this change breaks anything since it justs introduces additional functionality, but if it's considered too broad we could always add an admin setting page where the administrator can choose the search method for the masquerade block.
Comment #3
sreenivasparuchuri commentedFor Druapl 8 version
I created new module where I had extended the masquerade, so that now we can able to search with role,email,user id,username
Masquerade Extra
Comment #4
andypostI'm sure better to allow autocomplete to use view and create UI for that instead of hacking the query all the time
Comment #5
hargobindThe patch in #2 works great! I came here to submit something similar, but this is better than the one mine. I really like the addition of showing the email after the username.
Comment #6
ressaThanks everyone for working on this. In an attempt to help the maintainers, I am going through some of the Drupal 7 issues, and closing them, since Drupal 7 is EOL.
Maintainers should grant credit for the great work to the relevant users, even if the patch did not get committed: https://www.drupal.org/docs/develop/issues/issue-procedures-and-etiquett....
Since Drupal 7 is EOL and search seems not available in Drupal 11, we can probably close this issue, but feel free to re-open if this is still relevant, or we should consider adding this feature to Drupal 11?