Display author avatar within posts or pages

Adding this snippet to your wordpress theme within the loop will display the current authors avatar.

     echo get_avatar( get_the_author_email(), '60' ); 

Comments  Leave a Reply

  1. venkatesh sakthivel May 12, 2014 at 7:44 am

    hi Kevin, how to replace featured image of a post by author avatar. plz help me

  2. It have a way to catch this src link to put in my configurations? like <img src="/images/fake-avatar.jpg” title=”Richard Dawkings” class=”fl gravatar-author”> I’m won’t like a wordpress config to  gravatar author post used, I wanna use my way.

    1.  you can use this snippet to set a default gravatar image,

  3. sorry to bother you again … but it doesn’t do what i wanted than anyway mate …. cheers

Add a Comment

We're glad you have chosen to leave a comment. Please keep in mind that all comments are moderated according to our privacy policy, and all links are nofollow. Do NOT use keywords in the name field. Let's have a personal and meaningful conversation.

WordPress Launch Checklist

The Ultimate WordPress Launch Checklist

We've compiled all the essential checklist items for your next WordPress website launch into one handy ebook.
Yes, Send Me the Free eBook!