User role
-
Hello!
How to take the value of community role? such code does not work –add_filter('gform_field_value_um_user_role', 'gform_populate_um_user_role'); function gform_populate_um_user_role(){ $current_user = wp_get_current_user(); $user_id = $current_user->ID; $UM_User_Role = 'N/A'; if ($user_id) { global $ultimatemember; um_fetch_user( $user_id ); $UM_User_Role = $ultimatemember->user->get_role(); } return $UM_User_Role; }
Viewing 6 replies - 1 through 6 (of 6 total)
Viewing 6 replies - 1 through 6 (of 6 total)
- The topic ‘User role’ is closed to new replies.