diff options
| author | czaks <marcin@6irc.net> | 2014-02-24 15:29:26 +0100 |
|---|---|---|
| committer | czaks <marcin@6irc.net> | 2014-02-24 15:29:26 +0100 |
| commit | 75cca1ffb2a41a2381f5287fd9bb8ea292a9c281 (patch) | |
| tree | fc8bd165ac13da6bcf0e4f95c2bf25edfa9a4946 | |
| parent | 14c499f9d114d924ffa5564f732db66516480f1e (diff) | |
fix previous commit
| -rw-r--r-- | inc/config.php | 2 | ||||
| -rw-r--r-- | inc/functions.php | 3 | ||||
| -rw-r--r-- | templates/post_reply.html | 10 | ||||
| -rw-r--r-- | templates/post_thread.html | 16 |
4 files changed, 22 insertions, 9 deletions
diff --git a/inc/config.php b/inc/config.php index 2af0f391..6c7247b4 100644 --- a/inc/config.php +++ b/inc/config.php @@ -1074,7 +1074,7 @@ $config['dir']['home'] = ''; // Location of a blank 1x1 gif file. Only used when country_flags_condensed is enabled - $config['uri_blank'] = $config['root'] . 'static/blank.gif'; + // $config['image_blank'] = 'static/blank.gif'; // Static images. These can be URLs OR base64 (data URI scheme). These are only used if // $config['font_awesome'] is false (default). diff --git a/inc/functions.php b/inc/functions.php index 5b5f5bdd..a65bf720 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -168,6 +168,9 @@ function loadConfig() { if (!isset($config['dir']['static'])) $config['dir']['static'] = $config['root'] . 'static/'; + if (!isset($config['image_blank'])) + $config['image_blank'] = $config['dir']['static'] . 'blank.gif'; + if (!isset($config['image_sticky'])) $config['image_sticky'] = $config['dir']['static'] . 'sticky.gif'; if (!isset($config['image_locked'])) diff --git a/templates/post_reply.html b/templates/post_reply.html index fb240511..713ddac9 100644 --- a/templates/post_reply.html +++ b/templates/post_reply.html @@ -31,17 +31,17 @@ {% if config.display_flags and post.modifiers.flag %} <img {% if config.country_flags_condensed %} - class="flag flag-{{ post.modifiers.flag }}" src="{{ config.uri_blank }}" + class="flag flag-{{ post.modifiers.flag }}" src="{{ config.image_blank }}" {% else %} - class="flag" src="{{ config.uri_flags|sprintf(post.modifiers.flag) }}" + class="flag" src="{{ config.uri_flags|sprintf(post.modifiers.flag) }}" {% endif %} - style="{% if post.modifiers['flag style'] %} + style="{% if post.modifiers['flag style'] %} {{ post.modifiers['flag style'] }} {% else %} {{ config.flag_style }} {% endif %}" - {% if post.modifiers['flag alt'] %}alt="{{ post.modifiers['flag alt'] | e('html_attr') }}" - title="{{ post.modifiers['flag alt'] | e('html_attr') }}"{% endif %}> + {% if post.modifiers['flag alt'] %} alt="{{ post.modifiers['flag alt'] | e('html_attr') }}" + title="{{ post.modifiers['flag alt'] | e('html_attr') }}"{% endif %}> {% endif %} <time datetime="{{ post.time|date('%Y-%m-%dT%H:%M:%S') }}{{ timezone() }}">{{ post.time|date(config.post_date) }}</time> </label> diff --git a/templates/post_thread.html b/templates/post_thread.html index d922dabd..113444be 100644 --- a/templates/post_thread.html +++ b/templates/post_thread.html @@ -83,9 +83,19 @@ [<a class="ip-link" style="margin:0;" href="?/IP/{{ post.ip }}">{{ post.ip }}</a>] {% endif %} {% if config.display_flags and post.modifiers.flag %} - <img class="flag" src="{{ config.uri_flags|sprintf(post.modifiers.flag) }}" - style="{% if post.modifiers['flag style'] %}{{ post.modifiers['flag style'] }}{% else %}{{ config.flag_style }}{% endif %}" - {% if post.modifiers['flag alt'] %}alt="{{ post.modifiers['flag alt'] | e('html_attr') }}" title="{{ post.modifiers['flag alt'] | e('html_attr') }}"{% endif %}> + <img + {% if config.country_flags_condensed %} + class="flag flag-{{ post.modifiers.flag }}" src="{{ config.image_blank }}" + {% else %} + class="flag" src="{{ config.uri_flags|sprintf(post.modifiers.flag) }}" + {% endif %} + style="{% if post.modifiers['flag style'] %} + {{ post.modifiers['flag style'] }} + {% else %} + {{ config.flag_style }} + {% endif %}" + {% if post.modifiers['flag alt'] %} alt="{{ post.modifiers['flag alt'] | e('html_attr') }}" + title="{{ post.modifiers['flag alt'] | e('html_attr') }}"{% endif %}> {% endif %} <time datetime="{{ post.time|date('%Y-%m-%dT%H:%M:%S') }}{{ timezone() }}">{{ post.time|date(config.post_date) }}</time> </label> |
