Show field or other text for only certain user role

You can use own role name.

  1.  
  2. <?php global $user;
  3. // Check if the user has the authenticated user' role.
  4. if (in_array('authenticated user', $user->roles)) { ?>
  5. some text for field blah blah blah...
  6. <?php } ?>


Article Information
Article ID Categories Tags Levels Status
#23
Free
Solved