Skip to:
Content
Pages
Categories
Search
Top
Bottom

Comment authors are not linked to their profile

Viewing 11 replies - 1 through 11 (of 11 total)
  • Avatar of nickrita
    nickrita
    Participant

    @nickrita

    So, I try to find a solution.

    When I commentet Andy’s last post here, my nickname wasn’t linked to my profile, but a lot of other nicknames were.

    Why isn’t my nickname linked, but the other’s are?

    Maybe the answer to this question will be the solution to my problem.

    Avatar of nickrita
    nickrita
    Participant

    @nickrita

    Please, doesn’t anybody know a solution? I can’t make my site public as long as the comment-author-problem isn’t solved.

    Avatar of nickrita
    nickrita
    Participant

    @nickrita

    Okay, it took some tests and now there is the solution:

    The comment-authors are only linked to their profile, if the profile has content.

    Avatar of Xevo
    Xevo
    Participant

    @xevo

    I haven’t tried this myself yet, but I think the way to call a user profile link is bp_user_link(). Try that.

    Avatar of Lriggle
    Lriggle
    Participant

    @lriggle

    To get my blog comments to link to their Buddypress Member profiles, I had to create a custom comment function (explained here: http://codex.wordpress.org/Template_Tags/wp_list_comments ) and then create a link around the avatar. In the link I used <?php echo bp_core_get_userlink( $comment->user_id, false, true ) ?> as the href value.

    Avatar of member11
    member11
    Participant

    @member11

    Thanks Lriggle.

    Pardon my ignorance. Which file do you you edit and where do you place the code for this?

    Alternatively, is there a way to add some default content to a user’s profile on creation, so that the link immediately goes bacl to their BP Profile?

    Paul

    Avatar of member11
    member11
    Participant

    @member11

    For future reference –

    I tried setting a default value in a multiselect box for all new users.

    The member comment link doesn’t redirect immediately to the member’s profile, but it did work when I clicked ‘Save Changes’ in edit profile > even though I didn’t manually edit any content as such.

    So my theory (assuming no other fix), is to direct new members to their profiles after registration. Once they’ve saved changes then all should be ok.

    @Lriggle

    I’d still be interested to know more about your solution above…. as well.

    Avatar of Lriggle
    Lriggle
    Participant

    @lriggle

    @member11

    The theme I’m building is a parent theme, so I put the code I posted above in the single.php file. This is the page that shows a single blog post.

    Avatar of henrybaum
    henrybaum
    Participant

    @henrybaum

    Why are basic things so complicated in BP? This should be done by default. Anyway.

    That’s the full code to add in single.php? Wondering also where it goes. Not working under:

    <?php comments_template(); ?>

    Avatar of Xevo
    Xevo
    Participant

    @xevo

    @ Henry: The comments template can be found in the comments.php file. Although you will have to create your own comments loop if you want to add something like this.

    ( Normally themes use “wp_list_comments()”, including the 1.2 new bp theme )

    Avatar of henrybaum
    henrybaum
    Participant

    @henrybaum

    I’m still not getting this to work. Any hints where this can go?

    <?php echo bp_core_get_userlink( $comment->user_id, false, true ) ?>

Viewing 11 replies - 1 through 11 (of 11 total)

You must be logged in to reply to this topic.