diff options
Diffstat (limited to 'modules')
-rw-r--r-- | modules/comment.module | 8 | ||||
-rw-r--r-- | modules/comment/comment.module | 8 |
2 files changed, 12 insertions, 4 deletions
diff --git a/modules/comment.module b/modules/comment.module index aa4bcbb3b..6fd9793b8 100644 --- a/modules/comment.module +++ b/modules/comment.module @@ -449,9 +449,13 @@ function comment_thread_max($comments, $threshold, $pid = 0, $level = 0) { foreach ($comments as $comment) { if ($comment->pid == $pid) { - print "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\"><tr><td width=\"". ($level * 25) ."\"> </td><td>\n"; + if ($level) { + print "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\"><tr><td width=\"". ($level * 25) ."\"> </td><td>\n"; + } comment_view($comment, comment_links($comment, 0)); - print "</td></tr></table>\n"; + if ($level) { + print "</td></tr></table>\n"; + } comment_thread_max($comments, $threshold, $comment->cid, $level + 1); } diff --git a/modules/comment/comment.module b/modules/comment/comment.module index aa4bcbb3b..6fd9793b8 100644 --- a/modules/comment/comment.module +++ b/modules/comment/comment.module @@ -449,9 +449,13 @@ function comment_thread_max($comments, $threshold, $pid = 0, $level = 0) { foreach ($comments as $comment) { if ($comment->pid == $pid) { - print "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\"><tr><td width=\"". ($level * 25) ."\"> </td><td>\n"; + if ($level) { + print "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\"><tr><td width=\"". ($level * 25) ."\"> </td><td>\n"; + } comment_view($comment, comment_links($comment, 0)); - print "</td></tr></table>\n"; + if ($level) { + print "</td></tr></table>\n"; + } comment_thread_max($comments, $threshold, $comment->cid, $level + 1); } |