MyBB Community Forums

Full Version: [B] patch post per page after moving post between threads
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
--- showthread.php      2009-03-20 09:32:38.000000000 +0300
+++ showthread2.php     2009-03-20 09:15:17.000000000 +0300
@@ -684,7 +684,7 @@
                        $query = $db->query("
                                SELECT COUNT(p.pid) AS count FROM ".TABLE_PREFIX."posts p
                                WHERE p.tid='$tid'
-                               AND p.pid <= '".$mybb->input['pid']."'
+                               AND p.dateline <= (SELECT dateline FROM ".TABLE_PREFIX."posts p2 WHERE p2.pid = '".$mybb->input['pid']."') 
                                $visible
                        ");
                        $result = $db->fetch_field($query, "count");
Your job is to report the bug, our job is to create the patch.