Forums
-
- Forum
- Posts
-
- Installing BuddyPress
- 24,019
- How-to & Troubleshooting
- 129,639
- Creating & Extending
- 25,793
- Requests & Feedback
- 9,497
- Third Party Plugins
- 9,791
- Showcase
- 3,316
- Ideas
- 1,382
- Miscellaneous
- 9,179
-
In your get_user_name_display() function, you also need to declare $bp as global, otherwise it will not be able to pull the data from $bp->displayed_user->id.
So, do this:
function get_user_name_display() {
global $wpdb, $bp;