User Guide

Table Of Contents
632 Chapter 27: Building Dynamic Forms with cfform Tags
The cfform tag and its subtags also provide you with several methods for validating input data.
For example, you can perform the validation on the browser or on the server. You can check the
data type, or you can mask data input.
Individual
cfform tags have additional dynamic features. Several of the tags do not have HTML
counterparts, and others directly support dynamically populating the control from data sources.
Also, the
cfform tag preservedata attribute retains user input in a form after the user submits
the form, so the data reappears if the form gets redisplayed.
This chapter describes features of the
cfform tag and focuses on using several of the cfform child
tags that do not have HTML counterparts. The following chapters describe other features of
ColdFusion forms that you create using the
cfform tag:
Chapter 28, “Validating Data, on page 659
Chapter 29, “Creating Forms in Macromedia Flash,” on page 687
Chapter 30, “Creating Skinnable XML Forms,” on page 709
The cfform controls
The following table describes the ColdFusion controls that you use in forms created using the
cfform tag. You can use these tags only inside a cfform tag. Unless otherwise stated, these
controls are supported in HTML, Flash, and XML skinable forms.
Control Description For more information
cfapplet Embeds a custom Java applet in the form. Not
supported in Flash format forms.
“Embedding Java applets”
on page 655.
cfcalendar Displays an interactive Macromedia Flash
calendar that can be included in an HTML or
Flash format form. ignored in XML skinable
forms. The calendar lets a user select a date for
submission as a form variable.
The
cfcalendar tag in CFML
Reference
cfformgroup Creates a container control for organizing and
formatting multiple form controls. Used in the
cfform tag body of Macromedia Flash and XML
skinable forms. Ignored in HTML forms.
Chapter 29, “Creating Forms in
Macromedia Flash”,
Chapter 30, “Creating
Skinnable XML Forms”
cfformitem Inserts a horizontal line, a vertical line, or
formatted or unformatted text in a Flash form.
Used in the
cfform or cfformgroup tag body for
Flash and XML forms. Ignored in HTML forms.
Chapter 29, “Creating Forms in
Macromedia Flash”,
Chapter 30, “Creating
Skinnable XML Forms”
cfgrid Creates a Java applet or Flash data grid that you
can populate from a query or by defining the
contents of individual cells. You can also use
grids to insert, update, and delete records from a
data source.
“Creating data grids with the
cfgrid tag” on page 644
cfinput Equivalent to the HTML input tag, with the
addition of input validation.
“Creating a basic form”
on page 611