This Confluence has been LDAP enabled, if you are an ASF Committer, please use your LDAP Credentials to login. Any problems file an INFRA jira ticket please.

Child pages
  • Form Tags

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 4.0

...

Likewise, a form control could be populated by calling a JavaBean accessor, like getPostalCode. In the expression language, we can refer to the JavaBean property by name. An expression like "%{postalCode}" would in turn call getPostalCode.

Code Block
xmlxml
titleUsing Expressions to populate a form for editing
xml
<@s.form action="updateAddress">
    <@s.textfield label="Postal Code" name="postalCode" value="%{postalCode}"/>
    ...
</@s.form>

However, since the tags imply a relationship between the name and value, the value attribute is optional. If a value is not specified, by default, the JavaBean accessor is used instead.

Code Block
xmlxml
titlePopulating a form for editing, the easy way
xml
<@s.form action="updateAddress">
    <@s.textfield label="Postal Code" name="postalCode"/>
    ...
</@s.form>

...