WordPress.org

Ready to get started?Download WordPress

Forums

User Photo
User Photos not aligned correctly (9 posts)

  1. CurtDogg
    Member
    Posted 3 years ago #

    http://downandb.com/?p=455

    As pictured with the posts that actually have user photos, they seem to have a big space from the far left of the comment box to where it actually is. Any way I can fix this?

  2. zwanzmich
    Member
    Posted 3 years ago #

    yes. i have the same problem. already tried to decrease the size of photo thumbnails but they still are not aligned on the left side but instead appear above the text comments and moved inwards from the left border. as well the miss the border which is attached to all other avatars.
    I already had a look at comment.php of my theme but could not find anything. Any idea? THANKS!!

  3. Carsten Bach
    Member
    Posted 3 years ago #

    I had the same problem and solved it by adding the class="avatar" to the <img> tag generated by the plugin.

    You can find it in line 165.

    Would be nice to have it fixed in a coming version, so that nobody have to hack the original plugin.

  4. michaudg
    Member
    Posted 2 years ago #

    Thank you for the fix carstenbach!

  5. warclown
    Member
    Posted 2 years ago #

    Hi, line 165 in what document? The comments.php file only has 104 lines..

    Please help :)

  6. Carsten Bach
    Member
    Posted 2 years ago #

    Hi warclown,

    I added the class to the pluginfile itself user-photo.php.
    Hope this helps.

  7. empathy
    Member
    Posted 2 years ago #

    Thanks carstenback.

    Some clarification please:

    I had the same problem and solved it by adding the class="avatar" to the <img> tag generated by the plugin.

    Did you add the avatar class, or did you replace the photo class with avatar?

    I ask because I wonder what side effects changing the class from photo to avatar has on other uses of the avatar; for example, in author pages.

    Additionally,

    It would be nice to be able to completely bypass and avoid gravatar use and outbound calls/tracking to Gravatar. The options to bypass Gravatar depend on the global WP Gravatar fallback options enabled. I noticed some code that has been commented out that may manage that.

    In summary, I am going to pursue a solution to providing a default avatar in the case the user does not have a specific avatar uploaded/selected, aside from calling Gravatar for one.

  8. Carsten Bach
    Member
    Posted 2 years ago #

    He empathy,

    I really added the class, to keep things going were the avatar-class ist used by css.

    To have a default local fallback, you could hook the 'mystery-man' with something like this
    http://buildinternet.com/2009/02/how-to-change-the-default-gravatar-in-wordpress/

    Good luck!

  9. austinlyon
    Member
    Posted 2 years ago #

    I hate to bump up an old topic like this, but I guess it's better than making a new one. I too would like to see the missing class "avatar", and if possible "avatar-{$size}", added to the image tags created bu User Photo.

    The developers went through the trouble of adding the "photo" class, but for a plugin that supposedly works alongside both Gravatars and the get_avatar() function from pluggable.php, it seems that omitting the "avatar" class would cause a lot of trouble, as many themes, as well as wordpress' native function, use this class to differentiate their user identity photos (aka avatars) from other photos.

    In fact, just by skimming the forum, quite a few problems would be solved by this simple addition of 1 line of code - problems that some users users associate with the uploaded photo but are actually rooted in a CSS problem.

    It's a shame, because otherwise this plugin is really thorough, and easy to use to boot!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags