• Do not register here on develop.twiki.org, login with your twiki.org account. • Use Item7848 for generic doc work for TWiki-6.1.1. Use Item7851 for doc work on extensions that are not part of a release. More...Close • Anything you create or change in standard webs (Main, TWiki, Sandbox etc) will be automatically reverted on every SVN update. • Does this site look broken?. Use the LitterTray web for test cases.
It works to a degree. The part that doesn't work is that H3 lines appear as
---+++ [[%TOPIC%#11Mar2006001217][ ==11 Mar 2006:== Test 1 2 3]]
That is, the %TOPIC% isn't expanded, which in turn means that when the NewsPlugin puts the entries in the headline topic, they appear as:
* [[%TOPIC%#11Mar2006001217][ ==11 Mar 2006:== Test 1 2 3]]
That is, they are NOT a link to the relevant part of orignal news topic.
If the headline topic is further INCLUDE'd in another topic, a front page or portal, the situation gets even more screwed up.
There are really two issues here
How to get %TOPIC% to expand when you want it to
How to prevent it being expanded when you don't want it to.
We seem stuck with it not being expanded when the "COMMENT" is used.
This is an enhancement request, not a patch requirement.
CC
I disagree.
This is a case of the result not being what is expected.
The rest of TWiki can use templates that have %TOPIC% and %<nop>TOPIC% to produce the results I mention in my oints 1 & 2 above. Buit not in this situation.
Thus its at variance with what is expected and the behaviour of the rest of TWiki. I don't see how expecting it to behave like the rest of TWiki is an 'enhancement' as opposed to a 'requirement'.
Conformant and consitent behaviour is a requirement, surely?
-- AJA
No. Comment plugin follows the rules for expansion of variables on topic creation, and as you know %TOPIC% is not expanded on topic creation.
You want it to support then insertion of the generating topic name; fair enough, but that's an enhancement.
One way to do it would be to extend %COMMENT to support named parameters (like INCLUDE does). For example,
%COMMENT{target="FintleWoodleWix" topic="%TOPIC%"}%
When the COMMENT was triggered, %TOPIC would aready be expanded, and then you could use the named parameter %topic% in the comment template.
I've been thinking about doing something like this for a while now, but I haven't been able to interest a sponsor and as you know, without sponsorship things take longer to get done.
CC
Whatever... The parser doens't do what I expect.
If I use a template line to specify the 'location':
...
which still isn't what I expect.
And yes I've played with escapes and quotes on that one.
It works for "where=%TOPIC%" and "where=''"
So, any other suggestions for a work-aroound?
-- AJA
Without experimenting, I don't know if there is a workaround.
Reset priority to enhancement, as that is what is being requested here.
CC
I'm bouncing this to Item3647, which is a more general solution that is also appropriate for CommentPlugin.
CC