Fix for the image preview in the file filed on multilang sites

This commit is contained in:
Flavio Copes
2015-12-21 16:33:16 +01:00
parent b76b79e611
commit 08b2043dd3

View File

@@ -9,7 +9,7 @@
Use the "pagemediaselect" type instead.
{% else %}
{% if value %}
<img src="{{ base_url_relative_frontend == '/' ? '/' : base_url_relative_frontend ~ '/'}}{{ value }}" alt="{{ value|replace({(files.destination ~ '/'): ''}) }}" />
<img src="{{ uri.rootUrl == '/' ? '/' : uri.rootUrl ~ '/'}}{{ value }}" alt="{{ value|replace({(files.destination ~ '/'): ''}) }}" />
<a href="{{ uri.addNonce(base_url_relative ~ '/media/' ~ base64_encode(base_path ~ '/' ~ value) ~ '/task' ~ config.system.param_sep ~ 'removeFileFromBlueprint' ~ '/blueprint' ~ config.system.param_sep ~ files.blueprint ~ '/field' ~ config.system.param_sep ~ files.name ~ '/redirect' ~ config.system.param_sep ~ base64_encode(uri.path), 'admin-form', 'admin-nonce') }}">
<i class="fa fa-close"></i>
</a>