get meta data via:
$meta = $this->inContext( 'can_render_meta' )
. That contect is set in the view script, e.g. the meta data of the base topic is stored in context. However,
uses web and topic of the current topic.
This is a bug, visible in the new TopMenuSkin
if you in a web other than TWiki web and you have parents: The parent link will point to the TWiki web instead of the current web.
Test: This topic's parent is set to WebNotify
in current Bugs web. See parent "P", it points to TWiki.WebNotify
. It should point to Bugs.WebNotify
Sidenote: Context variables are global variables. Whoever implemented the context variables in TWiki made a bad design decision.
- 26 Apr 2010
Not sure what the best fix is:
- Use web name, topic name and meta data of current web.topic by default. Add web="" and topic="" parameter to override web.topic.
- Use web name, topic name and meta data of base web.topic by default. Add web="" and topic="" parameter to override web.topic.
Number 1 is more logical, and in line with other TWiki variables that take effect on current web.topic. But it is likely to break existing TWiki applications. Number 2 does not change spec for meta data reference, but is not logical.
- 26 Apr 2010
Hi Peter.. let us go with option 1 if it fixes the issue.
better solution can be brainstormed/implemented later.. after the release
- 27 Apr 2010
After re-considering I decided to go for option 2. Better to stay compatible. I added a new topic="" parameter (no web="" parameter). Docs updated at VarMETA
- 28 Apr 2010
This fix also fixed bug Item6386
: breadcrumb shows improper topic if used in top bar.
- 06 May 2010