fix paths in templates

This commit is contained in:
czaks 2014-04-06 21:48:31 +02:00
parent 586ce42044
commit e034b9179d
2 changed files with 53 additions and 22 deletions

View File

@ -93,7 +93,21 @@
) )
</span> </span>
</p> </p>
<a href="{{ config.uri_img }}{{ post.file }}" target="_blank"{% if post.thumb == 'file' or post.modifiers['is_file'] == '1' %} class="file"{% endif %}> <a href="
{% if post.file|extension == 'webm' %}
{{ config.root }}player.php?v={{ config.uri_img }}{{ post.file }}&amp;t={{ post.filename|e('url') }}&amp;loop=1
{% else %}
{{ config.uri_img }}{{ post.file }}
{% endif %}" target="_blank"{% if post.thumb == 'file' or post.modifiers['is_file'] == '1' or post.filename|extension == 'webm' %} class="file"{% endif %}>
{% if post.thumb|extension == 'webm' %}
<video autoplay class="post-image" src="{{ config.uri_thumb }}{{ post.thumb }}" poster="
{{ config.root }}
{% if config.file_icons[post.filename|extension] %}
{{ config.file_thumb|sprintf(config.file_icons[post.filename|extension]) }}
{% else %}
{{ config.file_thumb|sprintf(config.file_icons.default) }}
{% endif %}" style="width:{{ post.thumbwidth }}px;height:{{ post.thumbheight }}px"></video>
{% else %}
<img class="post-image" src=" <img class="post-image" src="
{% if post.thumb == 'file' %} {% if post.thumb == 'file' %}
{{ config.root }} {{ config.root }}
@ -107,6 +121,7 @@
{% else %} {% else %}
{{ config.uri_thumb }}{{ post.thumb }} {{ config.uri_thumb }}{{ post.thumb }}
{% endif %}" style="width:{{ post.thumbwidth }}px;height:{{ post.thumbheight }}px" alt="" /> {% endif %}" style="width:{{ post.thumbwidth }}px;height:{{ post.thumbheight }}px" alt="" />
{% endif %}
</a> </a>
{% endif %} {% endif %}
{{ post.postControls }} {{ post.postControls }}

View File

@ -41,8 +41,22 @@
{% endif %} {% endif %}
) )
</span></p> </span></p>
<a href="{{ config.uri_img }}{{ post.file }}" target="_blank"{% if post.thumb == 'file' or post.modifiers['is_file'] == '1' %} class="file"{% endif %}> <a href="
<img class="post-image" src=" {% if post.file|extension == 'webm' %}
{{ config.root }}player.php?v={{ config.uri_img }}{{ post.file }}&amp;t={{ post.filename|e('url') }}&amp;loop=1
{% else %}
{{ config.uri_img }}{{ post.file }}
{% endif %}" target="_blank"{% if post.thumb == 'file' or post.modifiers['is_file'] == '1' or post.filename|extension == 'webm' %} class="file"{% endif %}>
{% if post.thumb|extension == 'webm' %}
<video autoplay class="post-image" src="{{ config.uri_thumb }}{{ post.thumb }}" poster="
{{ config.root }}
{% if config.file_icons[post.filename|extension] %}
{{ config.file_thumb|sprintf(config.file_icons[post.filename|extension]) }}
{% else %}
{{ config.file_thumb|sprintf(config.file_icons.default) }}
{% endif %}" style="width:{{ post.thumbwidth }}px;height:{{ post.thumbheight }}px"></video>
{% else %}
<img class="post-image" src="
{% if post.thumb == 'file' %} {% if post.thumb == 'file' %}
{{ config.root }} {{ config.root }}
{% if config.file_icons[post.filename|extension] %} {% if config.file_icons[post.filename|extension] %}
@ -54,7 +68,9 @@
{{ config.root }}{{ config.spoiler_image }} {{ config.root }}{{ config.spoiler_image }}
{% else %} {% else %}
{{ config.uri_thumb }}{{ post.thumb }} {{ config.uri_thumb }}{{ post.thumb }}
{% endif %}" style="width:{{ post.thumbwidth }}px;height:{{ post.thumbheight }}px" alt="" /></a> {% endif %}" style="width:{{ post.thumbwidth }}px;height:{{ post.thumbheight }}px" alt="" />
{% endif %}
</a>
{% endif %} {% endif %}
<div class="post op"><p class="intro"{% if not index %} id="{{ post.id }}"{% endif %}> <div class="post op"><p class="intro"{% if not index %} id="{{ post.id }}"{% endif %}>
<input type="checkbox" class="delete" name="delete_{{ post.id }}" id="delete_{{ post.id }}" /> <input type="checkbox" class="delete" name="delete_{{ post.id }}" id="delete_{{ post.id }}" />