Title: Help with code
Last modified: May 29, 2021

---

# Help with code

 *  Resolved [teeboy4real](https://wordpress.org/support/users/teeboy4real/)
 * (@teeboy4real)
 * [5 years ago](https://wordpress.org/support/topic/help-with-code-20/)
 * Hello,
 * Please can you help with this code, I have this code in a menu in my theme and
   I want to display the badge beside the user’s name
 *     ```
       <li id="user-nav-user-profile" class="no-ajaxy">
       <a href="<?php echo bp_core_get_user_domain( $current_user->ID );?>" class="no-ajaxy">
       <?php echo get_avatar( $current_user->ID, 32 ); ?>
       <span>
       <?php echo $current_user->display_name; ?>
       <span class="user-nicename">
       <em>
       @<?php echo bp_core_get_username( bp_loggedin_user_id() ); ?>
       </em>
       </span>
       </span>
       </a>
       </li>
       ```
   
 * I want to display the verified badge beside <?php echo $current_user->display_name;?
   > in the code above
 * Thanks

Viewing 1 replies (of 1 total)

 *  Plugin Author [Themosaurus](https://wordpress.org/support/users/themosaurus/)
 * (@themosaurus)
 * [4 years, 8 months ago](https://wordpress.org/support/topic/help-with-code-20/#post-14965162)
 * Hi [@teeboy4real](https://wordpress.org/support/users/teeboy4real/),
 * To do that you can use the “get_user_badge” method from our plugin, like so :
 *     ```
       <?php global $bp_verified_member;
       echo $bp_verified_member->get_user_badge( $current_user->ID ); ?>
       ```
   
 * Hope this helps.
 * Regards,

Viewing 1 replies (of 1 total)

The topic ‘Help with code’ is closed to new replies.

 * ![](https://ps.w.org/bp-verified-member/assets/icon-256x256.jpg?rev=2097319)
 * [Verified Member for BuddyPress](https://wordpress.org/plugins/bp-verified-member/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/bp-verified-member/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/bp-verified-member/)
 * [Active Topics](https://wordpress.org/support/plugin/bp-verified-member/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/bp-verified-member/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/bp-verified-member/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [Themosaurus](https://wordpress.org/support/users/themosaurus/)
 * Last activity: [4 years, 8 months ago](https://wordpress.org/support/topic/help-with-code-20/#post-14965162)
 * Status: resolved