NOTE: If you are a developer, please use a private wiki based on foswiki/trunk on a daily base ...or use trunk.foswiki.org to view this page for some minimal testing.
Use Item9693 for docu changes for 1.2 and 2.0.

Item6024: Can't handle comment templates in subwebs

Priority: CurrentState: AppliesTo: Component: WaitingFor:
Normal Closed Engine    
It seems that the CommentPlugin can't handle templates that are in subwebs. I installed the BlogAddOn into a subweb (Sandbox/SubWeb). The BlogPostViewTemplate topic has the following comment plugin invocation:
%COMMENT{rows="6" cols="100" noform="on" type="blogpost" templatetopic="BlogPostCommentTemplate" target="%TOPIC%" button="%MAKETEXT{"Add comment"}%" }%

When TWiki renders a blog post, it emits the following error in the warning log:
 (TWiki::Plugins::CommentPlugin::Comment) Could not read template file 'Sandbox/SubWeb.BlogPostCommentTemplate'

I have verified that that topic does exist. If I install the BlogAddOn into a top level web (Sandbox), it works fine.

-- TWiki:Main/DiabJerius - 26 Sep 2008

OK, I tried to reproduce this on trunk and failed. Here's what I did:
  1. Created Web/SubWeb/BlogPostCommentTemplate.txt, pasted in a copy of CommentPluginTemplateExample
  2. Create Web/SubWeb/BlahBlah.txt and added Blah Blah %COMMENT{templatetopic="BlogPostCommentTemplate"}% Blah Blah to it
  3. A comment box appears, and accepts input, which is saved without errors.

However I see the problem on Release01x00, and it's a core bug so changed the attribution. The relevant fix for trunk was Item1704. Now fixed in 1.0.7 too.

-- CrawfordCurrie - 20 Sep 2009

ItemTemplate edit

Summary Can't handle comment templates in subwebs
ReportedBy TWiki:Main.DiabJerius
Codebase
SVN Range TWiki-5.0.0, Tue, 23 Sep 2008, build 17539
AppliesTo Engine
Component
Priority Normal
CurrentState Closed
WaitingFor
Checkins Foswikirev:5010
TargetRelease patch
ReleasedIn 1.0.7
Topic revision: r5 - 20 Sep 2009, KennethLavrsen
 
The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. see CopyrightStatement. Creative Commons LicenseGet Foswiki at sourceforge.net. Fast, secure and Free Open Source software downloads