diff --git a/themes/unconed/unconed.theme b/themes/unconed/unconed.theme index 39eca92318056a8c7a532df01b81c1a665a9239c..3b3aa865b2226315161743d5c447072b06eabea0 100644 --- a/themes/unconed/unconed.theme +++ b/themes/unconed/unconed.theme @@ -200,11 +200,15 @@ function commentControl($sid, $title, $threshold, $mode, $order) { <INPUT TYPE="submit" NAME="op" VALUE="Save"> </FONT> - <? - $result = mysql_query("SELECT COUNT(tid) FROM comments WHERE sid = $sid AND score < $threshold"); - if ($result && $number = mysql_result($result, 0)) { - ?> <BR><SMALL><FONT COLOR="<? echo "$this->fgcolor2"; ?>">There are at least <? echo $number; ?> comments below your threshold.</FONT></SMALL> <? - } + <? + + $number=discussion_num_filtered($sid, $pid); + if ($number>0) + { + ?> + <BR><SMALL>There are at least <? echo format_plural($number, "comment", "comments"); ?> comments below your threshold.</SMALL> + <? + } print "</TD></TR>"; print "</TABLE>";