Extension:Page Forms/Manual/The forminput parser function

The forminput parser function lets the user add or edit a given page with a form. When called, it creates a small HTML form that is submitted to Special:AddData. The parser function has the following basic usage:

All five arguments are optional.


 * form name : The name of the form to be used to add or edit the given page. The form name should be given without the 'Form:' namespace prefix. i.e. 'Book' and not 'Form:Book'.
 * size : The size of the text input field in the HTML form (default is 25).
 * value : The default value of the input field (default is blank).
 * button text : The text that will appear on the "submit" button (default is ...).
 * query string : The query string defines a set of values that get passed to the form (via Special:AddData).

The query string explained
The query string allows you to preload a form with a set of values. It should look like a typical URL query string; an example would be "namespace=User&User[Is_employee]=yes".

Query string parameters:


 * namespace : Used for adding or editing pages in a specific namespace. e.g. 'namespace=User:' will create the given page in the 'User' namespace.
 * super page : Used for adding or editing pages in a specific sub-page. e.g. 'super page=Manual' will create a page like 'Manual/page name'.
 * template-name[field-name] : Used for passing a specific value to a specific field in the form. e.g. 'Book[pages]=99'.
 * preload : (Advanced option!) This will preload the form with the contents of the given page. e.g. 'preload=stock page'. For more information, see Preloading data.

The query string can use magic words and other dynamic values, such as. This is a very powerful feature. For some examples, see: http://smw.referata.com/wiki/Special:BrowseData/Tips

= See also =
 * The formlink parser function.