As you probably know, FormSet is intended to assign default values to the fields in the form.

Problems arise due to the syntax of FormSet. Let us see an example:

This code...

[{FormSet form='exampleForm' description='this is the content of description textarea'}]
[{FormOpen form='exampleForm'}]
Description:\\
[{FormTextarea name='description' rows=5 cols=20}]
[{FormClose}]

... results in this form:

Description:

However, if the default text contains any single quote ('), this is rendered wrong:

Let us change description --> description's

[{FormSet form='exampleForm2' description='this is the content of description's textarea'}]
[{FormOpen form='exampleForm2'}]
Description:\\
[{FormTextarea name='description' rows=5 cols=20}]
[{FormClose}]

... results in this form:

Description:
Some text is missing... :-(

Solution#

Subtitute the single quote by its Unicode equivalent (')
[{FormSet form='exampleForm3' description='this is the content of description's textarea'}]
[{FormOpen form='exampleForm3'}]
Description:\\
[{FormTextarea name='description' rows=5 cols=20}]
[{FormClose}]
Description:
:-)
More FormSet Open Questions

Add new attachment

In order to upload a new attachment to this page, please use the following box to find the file, then click on “Upload”.
« This page (revision-6) was last changed on 09-Oct-2008 00:35 by MRA