The MU forums have moved to

Profile plugins and hooking into comment_author_link (6 posts)

  1. malandry
    Posted 16 years ago #


    I have developped a whole «community» plugin for Wordpress MU featuring member profiling, some statistics, up & down voting system like-digg but there's one little thing that annoy me and that I can't fix.

    I'm unable to hook into comment_author_link. I wish to provide a (dofollow) profile link to the registered author and a nofollow typical link to the anonymous commenter.

    An easy tricks would be to simply edit the template page and write a brand new function but that would not be compliant with every themes.

    Is there a more complex way to hook into it than
    add_action('comment_author_link', 'pa_author_link');




  2. malandry
    Posted 16 years ago #

    Oh well.... I guess typing it give me a clue where to look..

    add_action('get_comment_author_link', 'pa_author_link');
    function pa_author_link($content) {

    global $comment;

    if ($comment->user_id!=0) {
    $profile = get_authordata($comment->user_id);
    return "user_login."\">".$profile->display_name."";
    } else {
    return $content;


    Thanks anyway!

  3. honewatson
    Posted 16 years ago #

    Any chance of sharing your community plugin?

  4. malandry
    Posted 16 years ago #


    I will.. as soon as I'm done with it and I can package it.

    There's a LOT of custom coding mixed up with necessary well-known plugins so it's a bit messed up right now.

  5. honewatson
    Posted 16 years ago #

    Awesome! Looking forward to it.

  6. drmiketemp
    Posted 16 years ago #

    If you haven't discovered it yet:

    It's a collection site of wpmu plugins.

    Hope thi shelps,

About this Topic

  • Started 16 years ago by malandry
  • Latest reply from drmiketemp