In order to interface our TWiki with a mailing list archive, I embed the mailing list HTML pages in TWiki topics using the INCLUDE variable. However, the processing of the included pages breaks the links. For example:
The page /list-archive/msg00000.html (the first message in the archive) refers to the next message as msg00001.html. However, after processing by INCLUDE, the link is turned into: /list-archive/msg00000.html/msg00001.html This obviously doesn't work. Using rhe
parameter is not an option, as the links do need to be processed (otherwise the server would look for the next message in the TWiki /cgi-bin/twiki/bin/view/... directory).
I'm not entirely sure from your description how to reproduce this. However %INCLUDE does exactly what it says on the tin.... it includes the text of the other page, before rendering it with the rest of the page it is included in. What you are expecting is not
the spec of %INCLUDE, AFAICT.
If you want to protect the links, try surrounding the %INCLUDE with noautolink: for example:
that might work. Discarded, not a bug.
From the description on VarINCLUDE
When a page is included, normally VSF-E TWiki will process it, doing the following: 1) Alter relative links to point back to originating host
, 2) [...]
The behaviour I expect would be exactly that, however the relative links are not altered correctly. An original link in the included document (/list-archive/msg00000.html) would look like:
. After processing by %INCLUDE this becomes:
. Correct me if I'm wrong, but this does not look like intended behaviour.
I understand what you are saying, and I think I sympathise; however this is not a bug per se
, but a request for a spec change, so I changed this to Enhancement and created TWiki:Codev.RewriteIncludedRelativeLinks
Ah, I see what you mean, and why it doesn't work like I expected. And it would be very useful if it would correctly rewrite relative URL's in general, so thanks for looking at this. For the time being I can probably try to get the behaviour I want using the FilterPlugin
SVN 10720, patch posted to Codev topic.
In rare cases html tags spread over multiple lines were destroyed because of whitespace annihiliation. Replacing linefeeds with a space instead of nothing.
Closed in 4.0.5 KJL