diff --git a/inc/functions.php b/inc/functions.php index 3ddb7d4a..65e9dc32 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -614,7 +614,7 @@ function listBoards() { if ($config['cache']['enabled'] && ($boards = cache::get('all_boards'))) return $boards; - $query = query("SELECT * FROM ``boards`` LEFT JOIN ``board_create`` ON ``boards``.`uri` = ``board_create``.`uri` ORDER BY ``boards``.`uri`") or error(db_error()); + $query = query("SELECT ``boards``.`uri` uri, ``boards``.`title` title, ``boards``.`subtitle` subtitle, ``board_create``.`time` time FROM ``boards`` LEFT JOIN ``board_create`` ON ``boards``.`uri` = ``board_create``.`uri` ORDER BY ``boards``.`uri`") or error(db_error()); $boards = $query->fetchAll(); if ($config['cache']['enabled']) diff --git a/inc/mod/pages.php b/inc/mod/pages.php index 97ad60f8..3705ab44 100644 --- a/inc/mod/pages.php +++ b/inc/mod/pages.php @@ -809,7 +809,6 @@ function mod_page_ip($ip) { if ($config['mod']['dns_lookup']) $args['hostname'] = rDNS($ip); - $boards = listBoards(); foreach ($boards as $board) { openBoard($board['uri']); diff --git a/templates/header.html b/templates/header.html index 5e4d0f9f..b2e1f7b0 100644 --- a/templates/header.html +++ b/templates/header.html @@ -3,6 +3,7 @@ {% if config.meta_keywords %}{% endif %} + {% if config.meta_description %}{% endif %} {% if config.default_stylesheet.1 != '' and not mod %}{% endif %} {% if config.font_awesome %}{% endif %} {% if config.default_stylesheet.1 != '' %}{% endif %} diff --git a/templates/mod/view_ip.html b/templates/mod/view_ip.html index cec3f8ad..a4ea17bc 100644 --- a/templates/mod/view_ip.html +++ b/templates/mod/view_ip.html @@ -89,6 +89,7 @@ {{ bans|count }} {% trans bans_on_record %} {% for ban in bans %} + {% if ban.board in mod.boards or mod.boards.0 == '*' %}
@@ -164,6 +165,7 @@ + {% endif %} {% endfor %} {% endif %} diff --git a/templates/page.html b/templates/page.html index 41242105..0e9847bb 100644 --- a/templates/page.html +++ b/templates/page.html @@ -23,7 +23,7 @@
diff --git a/templates/themes/catalog/info.php b/templates/themes/catalog/info.php index 32695b4d..e97631e2 100644 --- a/templates/themes/catalog/info.php +++ b/templates/themes/catalog/info.php @@ -29,6 +29,13 @@ 'comment' => '(space seperated)', 'default' => implode(' ', $__default_boards) ); + + $theme['config'][] = Array( + 'title' => 'Use all boards - ∞chan', + 'name' => 'all', + 'type' => 'checkbox', + 'default' => false + ); $theme['config'][] = Array( 'title' => 'Update on new posts', diff --git a/templates/themes/catalog/theme.php b/templates/themes/catalog/theme.php index d3a837ca..fd293f27 100644 --- a/templates/themes/catalog/theme.php +++ b/templates/themes/catalog/theme.php @@ -11,14 +11,21 @@ // - post (a reply has been made) // - post-thread (a thread has been made) - $boards = explode(' ', $settings['boards']); + if ($settings['all']) { + $_boards = listBoards(); + $boards = array(); + foreach ($_boards as $i => $b) + $boards[] = $b['uri']; + } else { + $boards = explode(' ', $settings['boards']); + } if ($action == 'all') { foreach ($boards as $board) { $b = new Catalog(); $b->build($settings, $board); } - } elseif ($action == 'post-thread' || ($settings['update_on_posts'] && $action == 'post') || ($settings['update_on_posts'] && $action == 'post-delete') && in_array($board, $boards)) { + } elseif ($action == 'post-thread' || ($settings['update_on_posts'] && $action == 'post') || ($settings['update_on_posts'] && $action == 'post-delete') && (in_array($board, $boards) | $settings['all'])) { $b = new Catalog(); $b->build($settings, $board); }