WordPress.org

Ready to get started?Download WordPress

Forums

Social Author Bio
[resolved] Display in users comments (9 posts)

  1. clickarmada
    Member
    Posted 1 year ago #

    I'd like to display the icons in users comments, is it possible ?

    http://wordpress.org/extend/plugins/social-autho-bio/

  2. Nick Powers
    Member
    Plugin Author

    Posted 1 year ago #

    It currently doesn't do this on its own but should be straight forward, if you have a passing familiarity with PHP and WordPress, to add the following code to the comments:

    $icons = apply_filters('social_author_icons', $ID); echo $icons;

    This does sound like a nice option, I'll put it on the short list for upgrades.

  3. clickarmada
    Member
    Posted 1 year ago #

    I tried but it returns the article author social links in each comment instead of commenter social links.

    Also tried to display in user info page and link from each comment with this code:
    <a rel="nofollow" href ="<?php bloginfo('url'); ?>/?author=<?php echo $comment->user_id ?>"><?php echo $comment->comment_author?></a>

    Will try more :)

  4. Nick Powers
    Member
    Plugin Author

    Posted 1 year ago #

    Which file did you put it in for comments?

    I'm not sure if this is what you are looking for or not but in the latest version, to be released any day now, I have integrated Google+ so that the author's Google+ profile image shows in Google search results. It places their Google+ image and a link to their Google+ profile page, along with their social links at the bottom of their author page.

  5. clickarmada
    Member
    Posted 1 year ago #

    comments.php

    That's great news !

  6. clickarmada
    Member
    Posted 1 year ago #

    here a commenting example if you have time to take a look:

    http://clickarmada.com/blog/2012/09/28/photo-275/

  7. Nick Powers
    Member
    Plugin Author

    Posted 1 year ago #

    Send me a username / pw to nick AT nickpowers DOT info if you want me to take a look.

  8. Nick Powers
    Member
    Plugin Author

    Posted 1 year ago #

    For anyone interested, this was the code that was used to make this work:

    <?php
    $id = get_comment(get_comment_ID())->user_id;
    if( 0 != $id ) {
    $icons = apply_filters('social_author_icons', $id); echo $icons;
    }
    ?>

    The only caveat is that the default admin's comments do not display the icons. This is because comments by users without accounts report as id 0, the id of the default admin account.

  9. clickarmada
    Member
    Posted 1 year ago #

    Nick is the man !

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.