SID-00159: Simultaneous generation of 2 pages
| Status: |
Answered |
TWiki version: |
4.2.4 |
Perl version: |
5.10 |
| Category: |
CategoryTemplates |
Server OS: |
Win Server 2003 |
Last update: |
17 years ago |
I need to allow some users to have full right on the page and others just commenting rights. I am trying to do the following.
-Having a general web and 2 other subwebs: Content and Discussion.
-Content and Discussion webs are going to be populated with pages which are based on templates only
- Provide in the General web a form input with a create button where the user would input smth like
NewContent. The button would call two actions: one which will create
NewContent (loading the specific template from that subweb) and
NewContent (loading the subweb's template)
My question is how can I actually make two actions, for loading in a page two different templates since there is just one parameter templateTopic available for save script.
I would really need some help with this

Thank you in advance!
--
RoxanaCraciun - 04 Mar 2009
Discussion and Answer
Look into
TopicCreatePlugin.
Look also into conditionally show an edit link or view link based on topic exist. If topic does not exist, point it to the edit script with a specific template. Untested:
%IF{ "istopic 'Otherweb.%TOPIC%Discussion'"
then="[[Otherweb.%TOPIC%Discussion][Discussions]]"
else="[[%SCRIPTURL{edit}%/Otherweb/%TOPIC%Discussion?topictemplate=Otherweb.DiscussionTemplate][Create discussion page]]"
}%
A custom
CommentPlugin template might come in handly, as we have here in the support forum.
--
PeterThoeny - 04 Mar 2009
I managed to make it work partially. Now I have some issues which are concerned with usability.
After I create the comments and include the comment page into the topic page, every time I add a comment I have to migrate to the discussion page of the topic and I don't like that. Do you have any idea how to change that?
--
RoxanaCraciun - 12 Mar 2009
The save script understands a
redirectto parameter. See details at
CommentPlugins and
TWikiScripts.
--
PeterThoeny - 12 Mar 2009
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.