Question
Problem:
I have a Topic that uses images that are displayed with:
<img src="%ATTACHURLPATH%/intro.jpg" alt="intro.jpg" width='758' height='584' />
I have updated
Intro.jpg several times over the months so there are 3 revisions. I have also updated the Topic body with new text. When I go back to a previous revision of the Topic text, the latest and greatest
into.jpg is displayed. I would like it to display the attachment revision that was in effect when the topic text revision was saved.
I have tried using:
<img src="%SCRIPTURL{viewfile}%/%WEB%/%TOPIC%?filename=intro.jpg;rev=1" alt="intro.jpg" width='758' height='584' />
This works, but it requires I manually update each link when I update the attachment.
Question: Is there code for a link I can use that looks at the revision date of the topic text, and uses this date to display the attachment that has a date not greater than the topic text date? For example. If I want to go back to
r6 of my topic text, which has a date of 6/6/07, the
img src= will show the
Intro.jpg that has the date closest to 6/6/07 without being newer?
Environment
--
TWikiGuest - 20 Mar 2008
Answer
If you answer a question - or someone answered one of your questions - please remember to edit the page and set the status to answered. The status selector is below the edit box.
An example of what I want to do:
<img src="%SCRIPTURL{viewfile}%/%WEB%/%TOPIC%?filename=intro.jpg;date<=%REVINFO{"$date"}% alt="intro.jpg" width='758' height='584' />
--
TWikiGuest - 01 Apr 2008
Sounds like a useful
FeatureRequest.
--
FranzJosefGigler - 01 Apr 2008
Could someone add this to the
FeatureRequest topic. I can't do it as
TWikiGuest. Thanks.
--
TWikiGuest - 10 Apr 2008
Closing this question after more than 30 days of inactivity. Feel free to re-open if needed.
--
PeterThoeny - 03 Jun 2008