• 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.

See the example in CommentPluginExamples (template in CommentPluginTemplates): writing this form:

<form method="post" action="%SCRIPTURL{save}%/%WEB%/%TOPIC%">
<input type="hidden" name="origurl" value="%SCRIPTURL{view}%/%BASEWEB%/%BASETOPIC%" />

... so explicitely adding a form around the prompt box and hidden field origurl:

%COMMENT{type="target" noform="on" target="%COMMENT_TOPIC%"}% %BR%

... will render a field outside of the form:

<input type="hidden" name="comment_action" value="save" /><input type="hidden" name="comment_type" value="target" /><input type="hidden" name="comment_index" value="14" /> <br />

... and will cause the form to fail.

Leaving out noform="on" will make things work but renders 2 form tags.

In fact, leaving out the form around custom hidden fields make things still work despite of the doc. The template form should look like this then:

<input type="hidden" name="origurl" value="%SCRIPTURL{view}%/%BASEWEB%/%BASETOPIC%" />

I am not sure if this is a bug or unclear documentation


A bit of both, I'm afraid. Really allowing forms in templates was ill considered, and has hardly been used (as evidenced by this report) so I'm inclined to remove it.


I think my mistake was to combine a custom form within a "promptbox" DEF. I have added a new example noform that works and may serve as test case as well.

Closing this item.


Summary CommentPlugin noform="on" does not work, or unclear documentation
ReportedBy TWiki:Main.ArthurClemens

SVN Range TWiki-4.1, Tue, 28 Nov 2006, build 12081
AppliesTo Extension
Component CommentPlugin
Priority Normal
CurrentState Closed

Checkins 12147 12148 12274 12275
TargetRelease n/a
Edit | Attach | Watch | Print version | History: r9 < r8 < r7 < r6 < r5 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r9 - 2006-12-15 - ArthurClemens
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2019 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback