Tags:
create new tag
, view all tags

SID-00014: CommentPlugin: No such template

Status: Answered Answered TWiki version: 4.1.2 Perl version: 5.10.0
Category: CommentPlugin Server OS: Debian GNU/Linux lenny, kernel 2.6.26 Last update: 3 years ago

On TWiki 4.1 I have created a custom template for the CommentPlugin, but when I try to use it I get No such template def TMPL:DEF{PROMPT:easy_action}

This is all in the sandbox. The sandbox has a topic UserCommentsTemplate with defines that template. The documentation shipped with that version seems to say this should work, i.e., the comment plugin will pick up my template from UserCommentsTemplate:

%TMPL:DEF{PROMPT:easy_action}%
<br />
<table width="90%" border="1" cellpadding="1" cellspacing="1">
  <tbody>
    <tr>
      <td colspan="4" rowspan="1"><b>Add new action item</b></td>
    </tr>
    <tr>
      <td align="right" width="30%">Description:</td>
      <td colspan="4" rowspan="1"><input type="text" size="80" name="action_comment" value="" /></td>
    </tr>
    <tr>
      <td align="right" width="30%">Assigned to:</td>
      <td width="25%"><select name="action_who"> <option>
%SEARCH{"%META:FORM.*[U]serForm" web="%MAINWEB%" format="<option>$topic</option>" sort="topic" excludetopic="Test*, TWiki*" separator=" "}%</option></select></td>
      <td align="right"><input %DISABLED% type="submit" value="%button|Add action%" /></td>
    </tr>
  </tbody>
</table>
%TMPL:END%

%TMPL:DEF{OUTPUT:easy_action}%%POS:BEFORE%%ACTION{who="%<nop>URLPARAM{"action_who"}%"  notify="Main.RossBoylan" creator="Main.RossBoylan" created="06 Jan 2009 - 14:11"}% %<nop>URLPARAM{"action_comment" newline="<br />"}%<br />
%TMPL:END%

I do have some plain text before and after the templates.

P.S. Searching text and titles for "No such template" produces no hits, even though it appears in NoSuchTemplateDef. It would be nice if that could be found.

-- RossBoylan - 06 Jan 2009

Discussion and Answer

I find the template include functionality of the CommentPlugin a bit confusing, I had issues myself in the past with a UserCommentsTemplate that could not be found.

Nowadays I usually create a custom comment template in its own page and point the %COMMENT to it. See live example in this Support web at SupportCommentTemplate and WebTopicEditTemplate (do a "raw view" on both)

-- PeterThoeny - 06 Jan 2009

I'm not following. SupportCommentTemplate doesn't use !

The latest 4.2 TWiki contains that CommentPlugin version. Either upgrade to the latest TWiki, or upgrade to the latest CommentPlugin.

-- PeterThoeny - 07 Jan 2009

WebTopicEditTemplate has what I think is the key, the use of templatetopic="...." in the %COMMENT%. But that doesn't help when I try it. CommentPlugin does not list templatetopic as a keyword.

-- RossBoylan - 07 Jan 2009

The SupportCommentTemplate contains the definition of the custom template, in lieu of the UserCommentsTemplate. The UserCommentsTemplate has an escaped %COMMENT, pointing to the SupportCommentTemplate. The Plugins/CommentPlugin processes a templatetopic parameter; upgrade your plugin if it is old.

-- PeterThoeny - 07 Jan 2009

It appears templatetopic entered at r13311, and that r12750 shipped with TWiki 4.1. Is the failure of %COMMENT% to find the customizing template something I should file a bug on? That's assuming the problem persists with the newer version; I see nothing in the changelog indicating a fix.

-- RossBoylan - 07 Jan 2009

Change status to:

ALERT! If you answer a question - or have a question you asked answered by someone - please remember to edit the page and set the status to answered. The status is in a drop-down list below the edit box.

SupportForm
Status Answered
Title CommentPlugin: No such template
SupportCategory CommentPlugin
TWiki version 4.1.2
Server OS Debian GNU/Linux lenny, kernel 2.6.26
Web server apache 2.2.9
Perl version 5.10.0
Topic attachments
I Attachment Action Size Date Who Comment
HTMLhtml twiki-configure.html manage 159.6 K 2009-01-06 - 22:14 RossBoylan configuration
Topic revision: r7 - 2009-01-10 - PeterThoeny
 
Twitter Delicious Facebook Digg Google Bookmarks E-mail LinkedIn Reddit StumbleUpon    
  • Download TWiki
TWiki logo Powered by PerlIdeas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2012 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.