diff options
Diffstat (limited to 'modules/tracker/tracker.module')
-rw-r--r-- | modules/tracker/tracker.module | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/tracker/tracker.module b/modules/tracker/tracker.module index 5f2a9fcc6..49fceb724 100644 --- a/modules/tracker/tracker.module +++ b/modules/tracker/tracker.module @@ -34,12 +34,12 @@ function tracker_comments($id = 0) { $cresult = db_query("SELECT * FROM comments WHERE timestamp > $period AND uid = '". check_input($id) ."' AND nid = '$node->nid' ORDER BY cid DESC"); } else { - $cresult = db_query("SELECT * FROM comments WHERE timestamp > $period AND nid = '$node->nid' ORDER BY cid DESC"); + $cresult = db_query("SELECT c.*, u.name FROM comments c LEFT JOIN users u ON c.uid = u.uid WHERE c.timestamp > $period AND c.nid = '$node->nid' ORDER BY c.cid DESC"); } $output .= "<ul>"; while ($comment = db_fetch_object($cresult)) { - $output .= " <li><a href=\"node.php?id=$node->nid&cid=$comment->cid&pid=$comment->pid#$comment->cid\">". check_output($comment->subject) ."</a> (". t("replies") .": ". comment_num_replies($comment->cid) .") ". (comment_is_new($comment) ? "<span style=\"color: red;\">*</span>" : "") ."</li>\n"; + $output .= " <li><a href=\"node.php?id=$node->nid&cid=$comment->cid&pid=$comment->pid#$comment->cid\">". check_output($comment->subject) ."</a> by <a href=\"module.php?mod=user&op=view&id=$comment->uid\">". check_output($comment->name) ."</a> (". t("replies") .": ". comment_num_replies($comment->cid) .") ". (comment_is_new($comment) ? "<span style=\"color: red;\">*</span>" : "") ."</li>\n"; } $output .= " </ul>\n"; } |