Quote:
Originally Posted by raefor
you can try this one
|
:sorry: not work.. comments not editing..help pleaz :shock:
comments.php
Line 128
PHP Code:
begin_frame("" . COMMENTS . "");
$subres = mysql_query("SELECT COUNT(*) FROM comments WHERE $type = $id") or die(mysql_error());
$subrow = mysql_fetch_array($subres);
$commcount = $subrow[0];
if ($commcount) {
list($pagertop, $pagerbottom, $limit) = pager(10, $commcount, "comments.php?id=$id&type=$type&");
$commquery = "SELECT comments.id, text, user, comments.added, avatar, signature, username, title, class, uploaded, downloaded, privacy, donated FROM comments LEFT JOIN users ON comments.user = users.id WHERE $type = $id ORDER BY comments.id $limit";
$commres = mysql_query($commquery) or die(mysql_error());
}else{
unset($commres);
}
if ($commcount) {
print($pagertop);
commenttable($commres);
print($pagerbottom);
}else {
print("<BR><b><CENTER>" . NOCOMMENTS . "</CENTER></b><BR>\n");
}
echo "<CENTER>";
echo "<form name=\"comment\" method=\"post\" action=\"comments.php?type=$type&id=$id&takecomment=yes\">";
echo "".textbbcode("comment","body")."<br>";
echo "<input type=\"submit\" class=btn value=\"Add Comment\" />";
echo "</form></CENTER>";
end_frame();
stdfoot();
?>