Tags:
create new tag
view all tags

Question

I have a page that allows people to add items to an agenda list. I would like to be able to disable the commenting at a certain point and if necessary open it again. Is there a variable that I can add to the %Comment tag that can turn on and off the commenting capabilities?

Environment

TWiki version: TWikiRelease04x01x00
TWiki plugins: DefaultPlugin, EmptyPlugin, InterwikiPlugin
Server OS:  
Web server: Apache
Perl version: 5.6
Client OS: Mac OS 10.4
Web Browser: Firefox
Categories: Plugins

-- XochipalaValdez - 20 Jan 2007

Answer

ALERT! If you answer a question - or someone answered one of your questions - please remember to edit the page and set the status to answered. The status selector is below the edit box.

I have not tried this, but an %IF{}% listing a conditional %COMMENT% based on a TWiki variable should work. See VarIF.

-- PeterThoeny - 21 Jan 2007

-- XochipalaValdez - 09 Feb 2007

Peter's suggestion works for a simple %COMMENT%, but fails for %COMMENT% with attributes. For example:

%IF{"context authenticated" then='%COMMENT{type="above"}%'}%

results in the following partial content rendered into the response:

<div class="commentPlugin commentPluginPromptBox"><table border="0" cellpadding="0" cellspacing="0"><tr valign="middle"><td>&lt;textarea  rows="3" cols="70" name="comment" class="twikiInputField" wrap="soft" onfocus="if(this.value==
<p />

-- SteveIms - 21 Feb 2007

Closing this question after more than 30 days...

-- PeterThoeny - 02 Apr 2007

Change status to:
Edit | Attach | Watch | Print version | History: r5 < r4 < r3 < r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r5 - 2007-04-02 - PeterThoeny
 
  • Learn about TWiki  
  • Download TWiki
This site is powered by the TWiki collaboration platform Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2026 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.