From 4014682882d0b390dc099d05e6701521e5f64a31 Mon Sep 17 00:00:00 2001 From: Marcin Ɓabanowski Date: Wed, 22 Apr 2015 05:54:48 +0200 Subject: fileboard support --- inc/display.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'inc/display.php') diff --git a/inc/display.php b/inc/display.php index 65525ab9..e7fb9320 100644 --- a/inc/display.php +++ b/inc/display.php @@ -453,7 +453,8 @@ class Thread { event('show-thread', $this); - $built = Element('post_thread.html', array('config' => $config, 'board' => $board, 'post' => &$this, 'index' => $index, 'hasnoko50' => $hasnoko50, 'isnoko50' => $isnoko50, 'mod' => $this->mod)); + $file = ($index && $config['file_board']) ? 'post_thread_fileboard.html' : 'post_thread.html'; + $built = Element($file, array('config' => $config, 'board' => $board, 'post' => &$this, 'index' => $index, 'hasnoko50' => $hasnoko50, 'isnoko50' => $isnoko50, 'mod' => $this->mod)); return $built; } -- cgit v1.3 From 6d4e75624063fe6077a654378af9763e32a1c0e8 Mon Sep 17 00:00:00 2001 From: czaks Date: Fri, 11 Sep 2015 12:49:30 +0200 Subject: fix a bug for some bad database state. thanks Seisatsu for testing --- inc/display.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'inc/display.php') diff --git a/inc/display.php b/inc/display.php index e7fb9320..90cf3434 100644 --- a/inc/display.php +++ b/inc/display.php @@ -354,7 +354,7 @@ class Post { } if (isset($this->files) && $this->files) - $this->files = json_decode($this->files); + $this->files = @json_decode($this->files); $this->subject = utf8tohtml($this->subject); $this->name = utf8tohtml($this->name); @@ -404,7 +404,7 @@ class Thread { } if (isset($this->files)) - $this->files = json_decode($this->files); + $this->files = @json_decode($this->files); $this->subject = utf8tohtml($this->subject); $this->name = utf8tohtml($this->name); -- cgit v1.3