diff options
author | Dries Buytaert <dries@buytaert.net> | 2001-09-07 15:56:15 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2001-09-07 15:56:15 +0000 |
commit | b9947121d6cc384f18bb2ab97dbf274bf679324e (patch) | |
tree | 8960d6772be4f84479d81a55468ddab5b455be44 | |
parent | 19ff3e28fe221b819d16f055f7b37bf8a7985333 (diff) | |
download | brdo-b9947121d6cc384f18bb2ab97dbf274bf679324e.tar.gz brdo-b9947121d6cc384f18bb2ab97dbf274bf679324e.tar.bz2 |
- fix a _bug_ in "max threaded" mode
-rw-r--r-- | includes/comment.inc | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/includes/comment.inc b/includes/comment.inc index 1e9853325..30bf24e3e 100644 --- a/includes/comment.inc +++ b/includes/comment.inc @@ -246,20 +246,12 @@ function comment_thread_max($cid, $mode, $threshold, $level = 0, $dummy = 0) { $result = db_query("SELECT c.*, u.* FROM comments c LEFT JOIN users u ON c.author = u.id WHERE c.pid = '$cid' ORDER BY c.timestamp, c.cid"); - if ($level > 1) { - print "</td></tr></table>\n"; - } - - print "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\"><tr><td width=\"". ($level * 25) ."\"> </td><td>\n"; - while ($comment = db_fetch_object($result)) { + print "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\"><tr><td width=\"". ($level * 25) ."\"> </td><td>\n"; comment_view($comment, (comment_visible($comment, $threshold) ? comment_links($comment, 0) : 0)); - // print "comment at level $level\n"; - comment_thread_max($comment->cid, $mode, $threshold, $level + 1, $dummy + 1); - } - - if ($level < 2) { print "</td></tr></table>\n"; + + comment_thread_max($comment->cid, $mode, $threshold, $level + 1, $dummy + 1); } } |