Possible typo on the avatar plugin

Within the avatar_comment_display() function:

echo "<img src='" . $tmp_link . "/avatar/" . $tmp_size . ".png' id='" . $tmp_html_id . "' class='" . $tmp_html_class . "' height='" . $tmp_size . "' width='" . $tmp_size . "'>"

I actually had to put the http:// bit in there to make the url correct.

Thanks,
-drmike

    drmike

    Not a problem.

    Actually I'm having worse problems with the plugin. It's not finding the avatars for blogs which have them and displaying the root blog's avatar for those that don't have them. I've made a couple of changes but it's just making the problem worse.

    WPMU 1.3rc3 with the md5 hack on the upload directories.

    Having an avatar gives you the default:
    http://cynix.us/wp-content/default_avatar_16.png

    Not having an avatar gives you a broken url as noted above:

    kubrick.cynix.us/avatar/16.png

    Note the missing url.

    Adding in the http:// as above fixes the url but you still have the reversed call. I've fixed that by changing the following from true to false:

    if (strpos($tmp_link, $tmp_base_domain) == true){

    That's from the avatar.php file.

    Doing that though breaks output of those 5 sizes during uploading but the avatar does make it.

    Reuploading the files puts me back at square one but now I note that the avatar isn't showing on the test subblog where I uploaded an avatar.

    Please take a look at http://cynix.us The avatars are reversed as the cynix.us blog should have one, the others shouldn't but the Fresh Bananas should but it's showing the main blog one. (Although the link is broken.)

    Ain't this fun?

    drmike

    I figured it out. It works fine if you pass the 'http://' bit as part of the URL for the function avatar_comment_display call. Gotta admit that I'm scratching my head over this as I see you're stripping it out I believe.

    If you want to change the list-all plugin to display avatars, here's the code:

    // get blog url depending on vhost or not-vhost installtion
    if( defined( "VHOST" ) && constant( "VHOST" ) == 'yes' )
    echo $begin_wrap . avatar_comment_display('http://' . $tmp_domain,'16','avatar-id','avatar-class') . "<a href='http://" . $tmp_domain . $tmp_path . "'>" . $tmp_display . "</a>" . $end_wrap . "\n";
    else
    echo $begin_wrap . avatar_comment_display('http://' . $tmp_domain,'16','avatar-id','avatar-class') . "<a href='http://" . $tmp_domain . "'>" . $tmp_display . "</a>" . $end_wrap . "\n";

    As far as I can tell, you don't have to do that bit up top there. Sorry for the trouble.

    Thanks,
    -drmike