Adding Author Photo on Posts

Jul 19, 2010 at 8:26 PM

Hello all!

Thanks for your time in reading my post. I am wondering if there is anyway to have a photo displayed for the author in their posts. I went to the admin settings and under the profile tab added a Photo URL, but nothing shows up for that author. Are there any other changes i need to be making/missing? Thanks for any help!

Coordinator
Jul 20, 2010 at 10:26 AM

Even though you can enter the PhotoURL and other profile data, most of the Proflile data isn't actually being displayed anywhere.  At least the first half of the process is there!

You could modify your PostView.ascx file in your theme folder to output the image, if it exists for the Post Author.  This works with the Standard theme (probably other themes too):

<% if (Post.AuthorProfile != null && !string.IsNullOrEmpty(Post.AuthorProfile.PhotoURL)) { %>
    <img src="<%= Post.AuthorProfile.PhotoURL %>" border="0" alt="<%= Post.Author %>" />
<% } %>

Jul 20, 2010 at 3:15 PM

Sweet! works great, thank you!