Viewing 1 replies (of 1 total)
  • Thread Starter chrispink

    (@chrispink)

    Just to add this geezer has written some well dodgy code. AVOID!

    This outputs the photo and returns FALSE

    <? if (!userphoto_the_author_photo() == "" ) { ?>
    
             <? echo "here" ; ?>
    
             <?  } ?>

    and because life is too short to go off looking for other solutions and the backend does work.

    this function;

    if (userphoto_exists(get_the_author_meta( 'ID' )) )

    I found in the plugin does the trick (note the necessary parameter).

    so the whole code;

    if (userphoto_exists(get_the_author_meta( 'ID' )) ) {
         get_avatar(get_the_author_meta( 'ID' ));
    }

    outputs the author photo (if one exists) and nothing (no gravatar) if not.

Viewing 1 replies (of 1 total)
  • The topic ‘Logic issue’ is closed to new replies.