forked from leftypol/leftypol
Fix ukko scroll to post is too high / incorrect bug because of post_controls being display block on ukko threads. Add ordering by sticky to ukko2 and ukko3 forms for overboards
This commit is contained in:
parent
f2b73e1dff
commit
1f3effba04
6 changed files with 8 additions and 8 deletions
|
@ -73,7 +73,7 @@
|
|||
openBoard($post['board']);
|
||||
$thread = new Thread($post, $mod ? '?/' : $config['root'], $mod);
|
||||
|
||||
$posts = prepare(sprintf("SELECT * FROM ``posts_%s`` WHERE `thread` = :id ORDER BY `id` DESC LIMIT :limit", $post['board']));
|
||||
$posts = prepare(sprintf("SELECT * FROM ``posts_%s`` WHERE `thread` = :id ORDER BY `sticky` DESC, `id` DESC LIMIT :limit", $post['board']));
|
||||
$posts->bindValue(':id', $post['id']);
|
||||
$posts->bindValue(':limit', ($post['sticky'] ? $config['threads_preview_sticky'] : $config['threads_preview']), PDO::PARAM_INT);
|
||||
$posts->execute() or error(db_error($posts));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue