# Templates for [[CommentPlugin]] See [[CommentPlugin: Customisation|TWiki/CommentPlugin#Customisation]] for help. While this topic can be viewed as a TWiki topic, it is used by the [[CommentPlugin]] as a template file - see [[TWikiTemplates]]. The important content in here is in the verbatim blocks. The rest of the topic is just comments. hand See [[CommentPluginExamples]] to view rendered templates
WARNING: THIS FILE WILL BE OVERWRITTEN WHEN YOU UPGRADE THE COMMENT PLUGIN
Put your local templates into [[UserCommentsTemplate]] (create if it does not exist yet). **Local templates defined in that topic will override templates defined below.**
Table of Contents
## Template definitions ### Templates used in rest of file Generic prompt box used by other templates %TMPL:DEF{promptbox}%
 
%TMPL:END% Short comment, signed and dated %TMPL:DEF{outputoneliner}% * %URLPARAM{"comment"}% -- %WIKIUSERNAME% - %GMTIME{"$day $month $year"}%%TMPL:END% hand See rendered template [[Default|Main/CommentPluginExamples#Default]] ### User templates #### top Comments, signed and dated, added at top of file %TMPL:DEF{PROMPT:top}%%TMPL:P{promptbox}%%TMPL:END% %TMPL:DEF{OUTPUT:top}%%TMPL:P{outputoneliner}%%POS:TOP% %TMPL:END% hand See rendered template [[top|Main/CommentPluginExamples#top]] #### bottom Comments, signed and dated, added at end of file %TMPL:DEF{PROMPT:bottom}%%TMPL:P{promptbox}%%TMPL:END% %TMPL:DEF{OUTPUT:bottom}%%POS:BOTTOM%%TMPL:P{outputoneliner}%%TMPL:END% hand See rendered template [[bottom|Main/CommentPluginExamples#bottom]] #### above Comments, signed and dated, added immediately before anchor %TMPL:DEF{PROMPT:above}%%TMPL:P{promptbox}%%TMPL:END% %TMPL:DEF{OUTPUT:above}%%POS:BEFORE%%TMPL:P{OUTPUT:threadmode}%%TMPL:END% hand See rendered template [[above|Main/CommentPluginExamples#above]] #### bulletabove Bullet item added immediately before anchor. The input field width is passed with variable `inputsize`, for example: > %COMMENT{type="bulletabove" inputsize="20"}% %TMPL:DEF{PROMPT:bulletabove}% %TMPL:END% %TMPL:DEF{OUTPUT:bulletabove}% * %URLPARAM{"bullet_above_item"}%%POS:BEFORE% %TMPL:END% hand See rendered template [[bulletabove|Main/CommentPluginExamples#bulletabove]] #### threadmode Wiki thread mode comment, signed and dated %TMPL:DEF{PROMPT:threadmode}%%TMPL:P{promptbox}%%TMPL:END% %TMPL:DEF{OUTPUT:threadmode}%%POS:BEFORE% %URLPARAM{"comment"}% -- %WIKIUSERNAME% - %DATE% %TMPL:END% hand See rendered template [[threadmode|Main/CommentPluginExamples#threadmode]] #### belowthreadmode Comments, signed and dated, added recurse after comment box. %TMPL:DEF{PROMPT:belowthreadmode}%%TMPL:P{promptbox}%%TMPL:END% %TMPL:DEF{OUTPUT:belowthreadmode}%%POS:AFTER% ---++++ %WIKIUSERNAME% - %SERVERTIME% %URLPARAM{"comment"}% %TMPL:END% hand See rendered template [[belowthreadmode|Main/CommentPluginExamples#belowthreadmode]] #### below Comments, signed and dated, added immediately below anchor %TMPL:DEF{PROMPT:below}%%TMPL:P{promptbox}%%TMPL:END% %TMPL:DEF{OUTPUT:below}%%POS:AFTER%%TMPL:P{outputoneliner}% %TMPL:END% hand See rendered template [[below|Main/CommentPluginExamples#below]] #### tableprepend Comments, signed and dated, added at top of table below the anchor/location/COMMENT %TMPL:DEF{PROMPT:tableprepend}%%TMPL:P{promptbox}%%TMPL:END% %TMPL:DEF{OUTPUT:tableprepend}%%POS:AFTER%| %URLPARAM{"comment" newline="
"}% | %WIKIUSERNAME% | %SERVERTIME% | %TMPL:END% hand See rendered template [[tableprepend|Main/CommentPluginExamples#tableprepend]] #### tableappend Comments, signed and dated, added at end of table above the anchor/location/COMMENT %TMPL:DEF{PROMPT:tableappend}%%TMPL:P{promptbox}%%TMPL:END% %TMPL:DEF{OUTPUT:tableappend}%%POS:BEFORE%| %URLPARAM{"comment" newline="
"}% | %WIKIUSERNAME% | %SERVERTIME% | %TMPL:END% hand See rendered template [[tableappend|Main/CommentPluginExamples#tableappend]] #### after: Add before the comment box, after the last comment %TMPL:DEF{PROMPT:after}%%TMPL:P{promptbox}%%TMPL:END% %TMPL:DEF{OUTPUT:after}%%NOP%%TMPL:P{outputoneliner}% %POS:BEFORE%%TMPL:END% hand See rendered template [[after|Main/CommentPluginExamples#after]] #### action Action added to action table directly above comment box (requires TWiki:Plugins/ActionTrackerPlugin) %TMPL:DEF{PROMPT:action}% %TABLE{databg="#ffffff" tableborder="0" cellborder="0"}% | | | | | | | | | || | %TMPL:END% %TMPL:DEF{OUTPUT:action}%%POS:BEFORE%%AC%NOP%TION{who="%URLPARAM{"action_who"}%" due="%URLPARAM{"action_due"}%"}% %URLPARAM{"action_comment" newline="
"}%
- Created by %WIKIUSERNAME%, %SERVERTIME% %TMPL:END% hand See rendered template [[action|Main/CommentPluginExamples#action]] #### table Tablerows adding on end - TWiki:Main/FranzJosefSilli %TMPL:DEF{PROMPT:table}% %TABLE{databg="#ffffff" tableborder="0" cellborder="0"}% | | | | | | || | %TMPL:END% %TMPL:DEF{OUTPUT:table}%%POS:BEFORE%| %URLPARAM{"comment_date"}% | %WIKIUSERNAME% | %URLPARAM{"comment_city" }% | %TMPL:END% hand See rendered template [[table|Main/CommentPluginExamples#table]] #### toctalk Talk using TOC adding on end - TWiki:Main/FranzJosefSilli %TMPL:DEF{PROMPT:toctalk}% %TABLE{databg="#ffffff" tableborder="0" cellborder="0"}% | | | | | | || | %TMPL:END% %TMPL:DEF{OUTPUT:toctalk}% %POS:BEFORE%---++++ %SERVERTIME% %WIKIUSERNAME%: %URLPARAM{"comment_summary"}% %POS:BEFORE%%URLPARAM{"toctalk_comment_text" }% %POS:BEFORE% %TMPL:END% hand See rendered template [[toctalk|Main/CommentPluginExamples#toctalk]] #### bookmark Create a list of annotated bookmarks - TWiki:Main/FranzJosefSilli %TMPL:DEF{PROMPT:bookmark}% %TABLE{databg="#ffffff" tableborder="0" cellborder="0"}% | | | | | | | | | || | %TMPL:END% %TMPL:DEF{OUTPUT:bookmark}%%POS:BEFORE% * [[%URLPARAM{"comment_url" encode="entity"}%][%URLPARAM{"comment_link" encode="entity"}%]] %IF{" '%URLPARAM{"bookmark_comment_text" encode="entity"}%' = '' " then="" else="- "}%%URLPARAM{"bookmark_comment_text" encode="entity"}% %TMPL:END% hand See rendered template [[bookmark|Main/CommentPluginExamples#bookmark]] #### return Post to a different topic and return to here. The comment `target` is set in the `PROMPT`. In the form below the `redirectto` is set to the current (including) topic. %RED% Available with TWiki 4.1. %ENDCOLOR% %TMPL:DEF{returnpromptbox}% %TMPL:P{promptbox}% %TMPL:END% %TMPL:DEF{PROMPT:return}%%TMPL:P{returnpromptbox}%%TMPL:END% %TMPL:DEF{OUTPUT:return}%%POS:BEFORE%%TMPL:P{OUTPUT:threadmode}%%TMPL:END% hand See rendered template [[return|Main/CommentPluginExamples#return]] ## Include UserComments Including [[UserComments]]: %TMPL:INCLUDE\{"UserComments"\}%