I would like to build a privacy page for my users. I would like to give users a way to hide certain user meta fields for specific user roles. Lets say we have roles A, B and C and a custom user field 'e-mail'.
I created a user field called Privacy e-mail with option A, B, C (roles). I think it would be nice if a user can select which roles may NOT see this field. Role A is a quest (not logged in). B is an employee and C is an Agency. Let's say the user only wants to show the e-mail field to agencies. They can select option A and B so the field only shows up on users with an Agency role.
Thanks for your fast response. The point is that i needs to be on field basis.
So i have a field profile picture and e-mail for example. Both need 3 options: Show to guest, Show to Employee, Show to Employer.
My idea was this: a privacy custom field for every user field, with 3 checkboxes (guest, employee, employer).
Then a conditional: if logged in user has role employee AND user meta 'privacy-profile-picture' = true { don't show field }. Something like this :). It needs to check the role and privacy field.. I would like to use php for this.