Re: Search members by username
I don’t recommend to change the core files of buddypress. The best way to do it is to write a custom code (I don’t know how to guide you).
So if you don’t mind changing the core files, here is a quick way.
Open /buddypress/bp-core/bp-core-classes.php and change the
$sql = “AND pd.value LIKE ‘%%$search_terms%%'”;
to
$sql = “AND (pd.value LIKE ‘%%$search_terms%%’ OR u.user_login LIKE’%%$search_terms%%’)” ;
If someone can guide us how to do it in bp-custom.php, it would be great.