From 4f020ed7ea487bda704e6ffac6bdfd8de84d5e86 Mon Sep 17 00:00:00 2001 From: shish Date: Thu, 24 Jul 2008 14:05:40 +0000 Subject: [PATCH] for postgres support git-svn-id: file:///home/shish/svn/shimmie2/trunk@923 7f39781d-f577-437e-ae19-be835c7a54ca --- ext/comment/main.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/comment/main.php b/ext/comment/main.php index 3ba2139b..c143ebe2 100644 --- a/ext/comment/main.php +++ b/ext/comment/main.php @@ -203,9 +203,9 @@ class CommentList extends Extension { FROM comments GROUP BY image_id ORDER BY latest DESC - LIMIT ?,? + LIMIT ? OFFSET ? "; - $result = $database->Execute($get_threads, array($start, $threads_per_page)); + $result = $database->Execute($get_threads, array($threads_per_page, $start)); $total_pages = (int)($database->db->GetOne("SELECT COUNT(distinct image_id) AS count FROM comments") / 10);