add '?version=this' to src or href URLs for files and media assets to make sure that the selected version is displayed

git-svn-id: svn://svn.cy55.de/Zope3/src/loops/trunk@3030 fd906abe-77d9-0310-91a1-e0d9ade77398
This commit is contained in:
helmutm 2008-12-04 07:40:24 +00:00
parent e653d381e3
commit 40cee5d212
2 changed files with 9 additions and 5 deletions

View file

@ -42,7 +42,8 @@
<div metal:use-macro="views/node_macros/object_actions" /> <div metal:use-macro="views/node_macros/object_actions" />
<h3 tal:content="item/title">Title</h3><br /> <h3 tal:content="item/title">Title</h3><br />
<img src="#" <img src="#"
tal:attributes="src string:${view/url}/.target${view/targetId}/view" /> tal:attributes="src
string:${view/url}/.target${view/targetId}/view?version=this" />
<p><i tal:content="item/description">Description</i></p> <p><i tal:content="item/description">Description</i></p>
</div> </div>
</metal:block> </metal:block>
@ -57,7 +58,8 @@
<span class="button"> <span class="button">
<a href="#" <a href="#"
i18n:translate="" i18n:translate=""
tal:attributes="href string:${view/url}/.target${view/targetId}/download.html"> tal:attributes="href
string:${view/url}/.target${view/targetId}/download.html?version=this">
Download Download
</a> </a>
</span> </span>
@ -65,7 +67,8 @@
tal:condition="item/viewable | nothing"> tal:condition="item/viewable | nothing">
<a href="#" <a href="#"
i18n:translate="" i18n:translate=""
tal:attributes="href string:${view/url}/.target${view/targetId}/view"> tal:attributes="href
string:${view/url}/.target${view/targetId}/view?version=this">
View View
</a> </a>
</span> </span>

View file

@ -4,8 +4,9 @@
<h1 tal:content="item/title">Title</h1><br /> <h1 tal:content="item/title">Title</h1><br />
<p tal:define="url python: view.getUrlForTarget(item)"> <p tal:define="url python: view.getUrlForTarget(item)">
<a href="#" <a href="#"
tal:attributes="href string:${url}/view"><img tal:attributes="href string:${url}/view?version=this"><img
tal:attributes="src string:${url}/@@mediaasset.html?v=medium" /></a> tal:attributes="src
string:${url}/@@mediaasset.html?version=this&v=medium" /></a>
</p> </p>
<p><i tal:content="item/description">Description</i></p> <p><i tal:content="item/description">Description</i></p>
</div> </div>