• Resolved steveedin

    (@steveedin)


    A strange thing started happening today. All comments by Administrators and Editors (there are three) lost their display name and it was replaced with the name Anonymous.

    The correct name is on each user’s profile and in the database.

    I’m totally baffled. Any ideas?

    Thanks

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter steveedin

    (@steveedin)

    Solved. This code was in the functions.php. I’ll find another way to remove the URL link on the comment author’s name…

    /** Removes link to comment author website */
    function author_link(){
    global $comment;
    $comment_ID = $comment->user_id;
    $author = get_comment_author( $comment_ID );
    $url = get_comment_author_url( $comment_ID );
    if ( empty( $url ) || 'https://' == $url )
    $return = $author;
    else
    $return = "$author";
    return $return;
    }
    add_filter('get_comment_author_link', 'author_link');
    Thread Starter steveedin

    (@steveedin)

    In the theme_post_comments.php i just replaced…

    <?php comment_author_link(); ?>
    
    with
    
    <?php comment_author(); ?>

    All working now ??

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Administrators/Editors appear as 'Anonymous' in comments’ is closed to new replies.