• Do not register here on develop.twiki.org, login with your twiki.org account.
• Use View topic Item7848 for generic doc work for TWiki-6.1.1. Use View topic 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.

This is an intermittent problem that seems to depend on soemthing else that I have yet to determine, but it reproducable on my test platform in application webs

The CommentPlugin reads templates from CommentsTmpl The last line of this reads:

However, under many conditions, specifically use in the application web(s), referring to any template in the UserTemplates produces the error message:
 No such template def TMPL:DEF{PROMPT:forumtalk}

If this is changed to

the problem goes away.

So far as I can determine, the call to TWiki::Func::loadTemplate( ); and subsequent TWiki::Func::expandTemplate(); in TWiki::Plugins::CommentPlugin::Comment::_getTemplate() does not expand the %TWIKIWEB%. This is not becuase it is enclosed by a verbatim block.

The contents of /templates/comments.tmpl have the TWiki web hard coded, rather than using %TWIKIWEB%:

This 'hard coding' is not documented.

The comment in the code

    # Expand the template in the context of the web where the comment
    # box is (not the target of the comment!)
is misleading. I'm obviously interpreting it in a different way to that itneded by the author of the code.

This points to a bigger problem with the comment plugin, in that TWiki is not expanded when including templates using %TMPL:INCLUDE.

I have fixed the plugin so that it doesn't use this construct. Note that the standard templates topic will still include UserCommentsTmpl, but the documentation tells you to UserCommentTemplate (this allows a more generic style of customisation, including per-web and per-skin template customisation; see the revised plugin topic). Please re-open this issue if there are any further problems.

SVN 7251


Summary CommentPlugin doens't include site specific templates
ReportedBy TWiki:Main.AntonAylward
AppliesTo Extension
Priority Urgent
CurrentState Closed

Checkins 7251
Edit | Attach | Watch | Print version | History: r3 < r2 < r1 | Backlinks | Raw View |  Raw edit | More topic actions
Topic revision: r3 - 2005-11-01 - CrawfordCurrie
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2023 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback