BuddyPress Pseudo Role Field plugin adds a pseudo role field that works with BP Profile Search plugin and allows filtering users by role.
This plugin adds a "Pseudo Role" type xprofile field which can be used by the BP Profile search plugin to limit the user search to the user selected role. The roles are hidden from the users and that's why we call it pseudo field. To avoid any issue, when you declare an xprofile field with this type, do no make it part of the base group.
How to Use:-
- Create a field in your xprofile field screen with the type "Pseudo role"
- Edit your search form to include that field in search
- That's all.