This project is read-only.

Author Photos do not display in V2.0

Topics: Themes
Jan 12, 2011 at 10:44 PM

Hi All! I have recently updated my blog from v1.6 to 2.0, and from what I have seen thus far it is awesome! the update went slick and there were no problems there. I did however run into a small issue. On the postview.ascx i had it coded to bring in an author pic that corresponded with the publishing author. I had the "Photo URL" under "Profile" filled in and was pulling the URL from that using the following code:

<img class="postimg" src="<%= Post.AuthorProfile.PhotoURL %>" border="0" alt="<%= Post.Author %>" />


this line of code now throws and error which is as follows:


'BlogEngine.Core.AuthorProfile' does not contain a definition for 'PhotoURL' and no extension method 'PhotoURL' accepting a first argument of type 'BlogEngine.Core.AuthorProfile' could be found (are you missing a using directive or an assembly reference?)


is there something that changed from v1.6 to 2.0 that would make the above line of code not function properly anymore?


Thanks in advance!

Jan 13, 2011 at 8:58 AM

Try changing it from PhotoURL to PhotoUrl (note the difference in case).

Jan 14, 2011 at 3:34 PM

Worked Great! Thanks!