The
FormFieldListPlugin plugin provides an extended version of the predefined variable to access not only one, but a list of form field values.
Here we describe limitations of the plugin, how to fix them, discuss new features people would like to see, and how to implement them.
Rationale
Rationale
I have the idea to create a TWiki web containing descriptions of books and other literatur. To provide a uniform set of entries for each book (author, title, publisher, ISBN etc.) a TWiki Form seems to be a good choice for me.
This I prepared a form topic containing the form description. In addition this
topic includes the part to be rendered (within ... ) which is included in each book description topic.
The predefined variable has some restrictions because each one
is rendered by its own. Thus a series of where the field values are formatted as list items does not form a single list but a series of lists containing one item.
To remove this restriction
FormFieldListPlugin implements a variable %FORMFIELDLIST% which can be used with a comma-separated sequence of form field names. Because the rendering is done for the whole output of this variable, to get a list or a table containing all field values is trivial.
Background
It is my first attempt writing a TWiki plugin :-). And I am still experimenting with all the features, hooks, and whistles of TWiki.
Ideas
- %FORMFIELDLIST% is in principle backward compatible to . Why not replace/override the predefined variable with the extended one.
- Probably more options from are useful (e.g.,
header).
- Wildcard field name "*" to get all remaining field values (in definition order).
--
BerndRaichle - 04 Oct 2004
Feedback
Looks useful, but... did you consider rolling your code into the
FormFieldsPlugin ?
--
MartinCleaver - 01 Oct 2004
No, writing
FormFieldListPlugin I did not thought on editing forms. The plugin is intended to simplify showing form field values in the main topic text.
Looking at
FormQueryPlugin it seems that this plugin either contains the capabilities of
FormFieldListPlugin or can be extended to do so.
--
BerndRaichle - 04 Oct 2004
.zip checked into
CVSplugins:FormFieldListPlugin
--
WillNorris - 23 Nov 2004