ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Author list help

June 22, 2007 7:46am

Subscribe [2]
  • #1 / Jun 22, 2007 7:46am

    Sean C. Smith's avatar

    Sean C. Smith

    3818 posts

    I’ve got a list of authors on the side bar of this blog and it is working great. However what I would like to do is exclude authors from the list if they haven’t uploaded an avatar instead of using a default avatar.

    Is this possible? THe code I am currently using is below.

    
    									
  • #2 / Jun 22, 2007 8:08am

    silenz's avatar

    silenz

    1651 posts

    I think your are using the “Blogger Listing”-Plugin, right?
    Such a functionality would have to be integrated into the plugin. Shouldn’t be that hard.

  • #3 / Jun 22, 2007 8:49am

    Sean C. Smith's avatar

    Sean C. Smith

    3818 posts

    yeah I’m using the plugin. forgot about that since it’s been running for awhile. Will contact plugin author now.

  • #4 / Jun 22, 2007 8:55am

    silenz's avatar

    silenz

    1651 posts

    If you’re not afraid of a quick hack in the meantime:
    If you run the latest version 1.11, find this in pi.bloggers.php

    // Reset Flags
    $ap = "0";
    $aa = "0";

    It should be around line 196. Add the following line so it looks like that:

    if ($aa == 1) $tagdata="";
    // Reset Flags
    $ap = "0";
    $aa = "0";

    This will exclude authors without uploaded avatar.

  • #5 / Jun 22, 2007 9:04am

    Sean C. Smith's avatar

    Sean C. Smith

    3818 posts

    worked perfectly though I found the code at line 385.

    thanks

  • #6 / Jun 22, 2007 9:35am

    Sean C. Smith's avatar

    Sean C. Smith

    3818 posts

    hmmm…just noticed avatars display in FF but not in IE

  • #7 / Jun 22, 2007 9:49am

    silenz's avatar

    silenz

    1651 posts

    
    

    You have some curly brackets in the template that obviously don’t belong there.

  • #8 / Jun 22, 2007 10:03am

    Sean C. Smith's avatar

    Sean C. Smith

    3818 posts

    D’uh…. {slaps forehead}

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases