
769
DEVELOPING
COLDFUSION 9 APPLICATIONS
Requesting and Presenting Information
Las
t
upda
te
d 8/5/2010
Note:
Because of the Flash dynamic sizing rules, to ensure that the image displays properly, you sometimes have to specify
the
formitem
tag
height
attribute and the
width
and
height
attributes for the form or the containing
cfformgroup
tag. Also, the image always displays on a new line, not inline with text, and text that follows the image in your code
occupies any available space to the right of the image.
The
textformat
tag is specific to Flash, and has the following attributes:
For detailed descriptions of these tags, see the Flash documentation.
The following code creates a simple Flash form that consists of a formatted text area surrounded by horizontal rules:
<cfform name="myform" height="220" width="400" format="Flash" >
<!--- Use text formitem tag with style specifications for the heading. --->
<cfformitem type="text" style="fontWeight:bold; fontSize:14;">
Flash form with formatted text and rules
</cfformitem>
<!--- The spacer adds space between the text and the rule --->
<cfformitem type="spacer" height="2" />
<cfformitem type="hrule" />
<cfformitem type="html">
<b><font color="#FF0000" size="+4" face="serif">
This form has formatted text, including:</font></b><br>
<textformat blockindent="20" leading="2">
<li>colored text</li>
<li><i>italic and bold text</i></li>
<li>a bulleted list in an indented block</li>
</textformat>
<p><b>The text is preceded and followed by horizontal rules</b></p>
It also has a link to a web page.</b><br>
<a href="http://www.adobe.com/" target="_blank">
<font color="#0000FF"><u>
This link displays the Adobe home page in a new browser window
</u></font></a>
</cfformitem>
<cfformitem type="spacer" height="2"/>
<cfformitem type="hrule"/>
</cfform>
align
Horizontal alignment of the embedded image within the text field. Valid values are
left
and
right
. The default
value is
left
.
hspace
Number of pixels of horizontal space that surround the image where no text appears. The default value is
8
.
vspace
Number of pixels of vertical space that surround the image where no text appears. The default value is
8
.
Attribute
Description
blockindent
Block indentation, in points.
indent
Indentation from the left margin to the first character in the paragraph.
leading
Amount of leading (vertical space) between lines.
leftmargin
Left margin of the paragraph, in points.
rightmargin
Right margin of the paragraph, in points.
tabstops
Custom tab stops as an array of nonnegative integers. To specify tabs in text, use the \t escape character.
Attribute
Description