How to add specified user role’s all users list on drop down menu of Buddy Press custom add profile field

Is anyone an idea to add separate user role’s all users list in drop down menu of custom add profile field of Buddy Press ?

For example I have three types of roles. Admin,Doctor,Patient. I built Patient registration form. In this form I add the field using Buddy Press plugin’s sub menu as using below steps…

First I go to Users->Profile Fields->Add New Field->
Here in Name I add a name of field label “Assigned to”
Under the Type I select “Drop Down”
Now I stuck. I want here I need users list of my all users whose role is Doctor. In another words I want here my sites all registered Doctors list.

Is anyone have an idea to do this ?

Regards and Thanks in Advance

Read more here:: How to add specified user role’s all users list on drop down menu of Buddy Press custom add profile field

Leave a Reply

Your email address will not be published. Required fields are marked *