diff --git a/inc/config.php b/inc/config.php
index 1c6f94b6..6824e71d 100644
--- a/inc/config.php
+++ b/inc/config.php
@@ -127,6 +127,7 @@
// Static images
// These can be URLs OR base64 (data URI scheme)
define('IMAGE_STICKY', ROOT . DIR_STATIC . 'sticky.gif', true);
+ define('IMAGE_LOCKED', ROOT . DIR_STATIC . 'locked.gif', true);
define('DELETED_IMAGE', ROOT . DIR_STATIC . 'deleted.png', true);
define('ZIP_IMAGE', ROOT . DIR_STATIC . 'zip.png', true);
diff --git a/inc/display.php b/inc/display.php
index 555b78e8..ddced5c6 100644
--- a/inc/display.php
+++ b/inc/display.php
@@ -170,7 +170,7 @@
class Thread {
public $omitted = 0;
- public function __construct($id, $subject, $email, $name, $trip, $body, $time, $thumb, $thumbx, $thumby, $file, $filex, $filey, $filesize, $filename, $ip, $sticky, $root=ROOT, $mod=false) {
+ public function __construct($id, $subject, $email, $name, $trip, $body, $time, $thumb, $thumbx, $thumby, $file, $filex, $filey, $filesize, $filename, $ip, $sticky, $locked, $root=ROOT, $mod=false) {
$this->id = $id;
$this->subject = utf8tohtml($subject);
$this->email = $email;
@@ -190,6 +190,7 @@
$this->posts = Array();
$this->ip = $ip;
$this->sticky = $sticky;
+ $this->locked = $locked;
$this->root = $root;
$this->mod = $mod;
}
@@ -281,6 +282,8 @@
'id . ');"') . 'href="' . ($index?$this->root . $board['dir'] . DIR_RES . $this->id . '.html' . '#q' . $this->id:'javascript:void(0);') . '">'.$this->id.'' .
// Sticky
($this->sticky ? '' : '') .
+ // Locked
+ ($this->locked ? '' : '') .
// [Reply]
($index ? '[Reply]' : '') .
diff --git a/inc/functions.php b/inc/functions.php
index 57980283..99b8ac71 100644
--- a/inc/functions.php
+++ b/inc/functions.php
@@ -214,7 +214,7 @@
if($query->rowcount() < 1 && $page > 1) return false;
while($th = $query->fetch()) {
- $thread = new Thread($th['id'], $th['subject'], $th['email'], $th['name'], $th['trip'], $th['body'], $th['time'], $th['thumb'], $th['thumbwidth'], $th['thumbheight'], $th['file'], $th['filewidth'], $th['fileheight'], $th['filesize'], $th['filename'], $th['ip'], $th['sticky'], $mod ? '?/' : ROOT, $mod);
+ $thread = new Thread($th['id'], $th['subject'], $th['email'], $th['name'], $th['trip'], $th['body'], $th['time'], $th['thumb'], $th['thumbwidth'], $th['thumbheight'], $th['file'], $th['filewidth'], $th['fileheight'], $th['filesize'], $th['filename'], $th['ip'], $th['sticky'], $th['locked'], $mod ? '?/' : ROOT, $mod);
$posts = prepare(sprintf("SELECT `id`, `subject`, `email`, `name`, `trip`, `body`, `time`, `thumb`, `thumbwidth`, `thumbheight`, `file`, `filewidth`, `fileheight`, `filesize`, `filename`,`ip` FROM `posts_%s` WHERE `thread` = ? ORDER BY `time` DESC LIMIT ?", $board['uri']));
$posts->bindValue(1, $th['id']);
@@ -407,7 +407,7 @@
while($post = $query->fetch()) {
if(!isset($thread)) {
- $thread = new Thread($post['id'], $post['subject'], $post['email'], $post['name'], $post['trip'], $post['body'], $post['time'], $post['thumb'], $post['thumbwidth'], $post['thumbheight'], $post['file'], $post['filewidth'], $post['fileheight'], $post['filesize'], $post['filename'], $post['ip'], $post['sticky'], $mod ? '?/' : ROOT, $mod);
+ $thread = new Thread($post['id'], $post['subject'], $post['email'], $post['name'], $post['trip'], $post['body'], $post['time'], $post['thumb'], $post['thumbwidth'], $post['thumbheight'], $post['file'], $post['filewidth'], $post['fileheight'], $post['filesize'], $post['filename'], $post['ip'], $post['sticky'], $th['locked'], $mod ? '?/' : ROOT, $mod);
} else {
$thread->add(new Post($post['id'], $thread->id, $post['subject'], $post['email'], $post['name'], $post['trip'], $post['body'], $post['time'], $post['thumb'], $post['thumbwidth'], $post['thumbheight'], $post['file'], $post['filewidth'], $post['fileheight'], $post['filesize'], $post['filename'], $post['ip'], $mod ? '?/' : ROOT, $mod));
}
diff --git a/static/locked.gif b/static/locked.gif
new file mode 100644
index 00000000..d178c7b6
Binary files /dev/null and b/static/locked.gif differ