Adds a new page using a form.
(:newpageform:) string on a page and it will generate the form, which will help you to generate new pages. If the "group" field is left blank the new page will be created in "Main".
To use this script, simply copy it into your cookbook/ subdirectory and then add the following line to your configuration file:
Using a dropdown box
The default setting uses an inputbox for the groupname with the standard value "Main". Alternatively you can switch to a drop box. Follow those steps:
- on line 42 uncomment
//$NewGroup = array('Main', 'PmWiki');
- on line 51 uncomment
- on line 42 put all the groupnames which have to appear in the dropdown box between the brackets.
- On line 58 remove "
<td><input type='text' name='group'value='Main'></td></tr>";" and uncomment the section starting on line 59 and ending on line 63. The code to replace "
<td><input type='text' name='group'value='Main'></td></tr>";" starts with /* and ends with */
This is not really nice. Unfortunately I will only be able to make a revision of the script in January /February 2005.
Actual Version is 1.0.9
Laurent Meister kt007
Bugs & Discussion
The script seems not to work with pmwiki 2 beta29.
Doesn't work together with "Titledlinks." After installing this one, TitledLinks" gives only +++ -Han, 04/01/2004
Doesn't work together with "AlternateNamingScheme". To make it work, you have to type the precise name of the page in the form ie "My_page_with_a_l33t_name" to make it works. Calling the "make pagename function" could make it a lot easierd ... - LeFourbissime 11/01/2005
Doesn't work with spaces in the Page Name
-- Iram 01/12/05
When Edits are password protected, This doesn't work; after submitting a new page, the password is asked for, and then ... nothing. Neither the password is accepted, nor the page submitted. Han, 24 jan 2005
jmi: How do you get a form like
(:pitsform:) with many fields that are eventually displayed inside the text field of the new page ?
Could this recipe be merged with: Cookbook.NewPageBox? - Martin Fick