summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorctrlcctrlv <wizardchan@hush.com>2013-08-08 18:58:44 +0000
committerMichael Foster <savetheinternet@tinyboard.org>2013-08-11 21:08:19 +1000
commitacb4c47a9fe418284f2dab73d32bda75e34ed04a (patch)
tree1b83a4229d222b342b0177ffbfcc42a12db66c83
parent4bce3d75842c76934c112c11ebdfbc8705e40c8f (diff)
Allow for HTML in the board subtitle
Conflicts: inc/config.php
-rw-r--r--inc/config.php3
-rw-r--r--templates/index.html6
-rw-r--r--templates/mod/dashboard.html8
-rw-r--r--templates/thread.html8
4 files changed, 21 insertions, 4 deletions
diff --git a/inc/config.php b/inc/config.php
index fae7d2a5..d8a0ead2 100644
--- a/inc/config.php
+++ b/inc/config.php
@@ -615,6 +615,9 @@
// Number of reports you can create at once.
$config['report_limit'] = 3;
+ // Allow unfiltered HTML in board subtitles. This is useful for placing icons and links.
+ $config['allow_subtitle_html'] = false;
+
/*
* ====================
* Display settings
diff --git a/templates/index.html b/templates/index.html
index e32ac253..d5e6cd18 100644
--- a/templates/index.html
+++ b/templates/index.html
@@ -13,7 +13,11 @@
<h1>{{ board.url }} - {{ board.title|e }}</h1>
<div class="subtitle">
{% if board.subtitle %}
- {{ board.subtitle|e }}
+ {% if config.allow_subtitle_html %}
+ {{ board.subtitle }}
+ {% else %}
+ {{ board.subtitle|e }}
+ {% endif %}
{% endif %}
{% if mod %}<p><a href="?/">{% trans %}Return to dashboard{% endtrans %}</a></p>{% endif %}
</div>
diff --git a/templates/mod/dashboard.html b/templates/mod/dashboard.html
index e9fb7c9c..e2f7507d 100644
--- a/templates/mod/dashboard.html
+++ b/templates/mod/dashboard.html
@@ -8,7 +8,13 @@
-
{{ board.title|e }}
{% if board.subtitle %}
- <small>&mdash; {{ board.subtitle|e }}</small>
+ <small>&mdash;
+ {% if config.allow_subtitle_html %}
+ {{ board.subtitle }}
+ {% else %}
+ {{ board.subtitle|e }}
+ {% endif %}
+ </small>
{% endif %}
{% if mod|hasPermission(config.mod.manageboards) %}
<a href="?/edit/{{ board.uri }}"><small>[{% trans 'edit' %}]</small></a>
diff --git a/templates/thread.html b/templates/thread.html
index 97f8a3db..e8c43ef7 100644
--- a/templates/thread.html
+++ b/templates/thread.html
@@ -13,7 +13,11 @@
<h1>{{ board.url }} - {{ board.title|e }}</h1>
<div class="subtitle">
{% if board.subtitle %}
- {{ board.subtitle|e }}
+ {% if config.allow_subtitle_html %}
+ {{ board.subtitle }}
+ {% else %}
+ {{ board.subtitle|e }}
+ {% endif %}
{% endif %}
{% if mod %}<p><a href="?/">{% trans %}Return to dashboard{% endtrans %}</a></p>{% endif %}
</div>
@@ -42,4 +46,4 @@
ready();
{% endraw %}</script>
</body>
-</html> \ No newline at end of file
+</html>