1

I'm using the Simple Local Avatars plugin so my bbPress forumgoers can upload their own avatars. Now, when a user logs in, I want his/her avatar to display next to the relevant links (i.e. logout, edit profile, etc.). I tried the call below but it only keeps showing the default mystery man gravatar.

<?php echo get_avatar( $current_user->user_login, 48 ); ?>

Is there something I overlooked? How can I get the user's uploaded avatar to show up?

1 Answer 1

1

And of course as soon as I post the question, I find the answer.

slaps forehead

<?php
        global $current_user;
        get_currentuserinfo();
        echo get_avatar( $current_user->ID, 48 );
 ?>

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.