Difference between revisions of "Organic Design Simple Forms"

from HTYP, the free directory anyone can edit if they can prove to me that they're not a spambot
Jump to navigation Jump to search
(saving some notes for now)
 
(→‎form: "action" parameter)
 
Line 10: Line 10:
 
Parameters:
 
Parameters:
 
* '''target''': same as the HTML "target" parameter within a <form> tag; defines the name of the target window.
 
* '''target''': same as the HTML "target" parameter within a <form> tag; defines the name of the target window.
 +
* '''action''': supposedly this can set to be the next page loaded, but the ODSF code always seems to insert an extra "action=index.php" afterwards, overriding whatever value you set.
 +
 
===input===
 
===input===
 
These are basically the same parameters as the HTML <input> tag:
 
These are basically the same parameters as the HTML <input> tag:

Latest revision as of 21:41, 24 November 2007

Navigation

{{#lst:MediaWiki extensions|navbar}}: Organic Design Simple Forms

Overview

This is 3rd-party documentation for the "Simple Forms" MediaWiki extension by Organic Design. Although the official documentation is very good, it omitted some details and I didn't know where to start trying to reorganize it – so I'm starting here from scratch.

Functions

The extensions defines a collection of new functions ({{#function:param=val|param=val|...}}) which allow wiki editors to put HTML forms on a regular wiki page. The forms don't really do anything more than a normal HTML form would (although the power of wiki tools does give you some flexibility), but there are a number of other tools which can make use of the form data created by site visitors who use the form.

The main function is {{#form:...}}, with a list of subsidiary functions to define elements of the form.

form

Parameters:

  • target: same as the HTML "target" parameter within a <form> tag; defines the name of the target window.
  • action: supposedly this can set to be the next page loaded, but the ODSF code always seems to insert an extra "action=index.php" afterwards, overriding whatever value you set.

input

These are basically the same parameters as the HTML <input> tag:

  • name: the name which this parameter will have when it is passed as form data (e.g. for a GET form: ?name=value&name=value...)
  • type: type of input: hidden, text, textarea, submit
    • type=text (default type):
      • size is the width of the input box, in something approximating character-widths
    • type=submit: show a button; when pressed, the form data is submitted
      • value is the text to appear on the button
      • update: not sure what this does; the example says "update=result"