User Guide
cftree 347
Usage
This tag requires the client to download a Java applet. Downloading an applet takes time;
therefore, using this tag might be slightly slower than using an HTML form element or the
cfinput tag to get the same information.
For this tag to work properly. the browser must be JavaScript-enabled.
If the following conditions are true, a user’s selection from query data that populates this tag’s
options continues to display after the user submits the form:
• The cfform preserveData attribute is set to "Yes"
• The cfform action attribute posts to the same page as the form itself (this is the default), or
the action page has a form that contains controls with the same names as corresponding
controls on the user entry form
For more information, see the
cfform tag entry.
Example
<!--- This example shows the use of cftree in a cfform. The query takes a list
of
employees, and uses cftree and cfselect to display the results. cfgrid is
used to show an alternate means of displaying the same data --->
<!--- set a default for the employeeNames variable --->
<cfparam name = "employeeNames" default = "">
<!--- if an employee name has been passed from the form, set employeeNames
variable to this value --->
<cfif IsDefined("form.employeeNames")>
<cfset employeeNames = form.employeeNames>
</cfif>
align Optional • top
• left
• bottom
• baseline
• texttop
• absbottom
• middle
• absmiddle
• right
border Optional Yes • Yes
• No
hScroll Optional Yes • Yes: permits horizontal scrolling
• No
vScroll Optional Yes • Yes: permits vertical scrolling
• No
notSupported Optional Message to display if page that contains Java applet-based
form control is opened by browser that does not support
Java, or has Java support disabled. For example:
notSupported = "<b> Browser must support Java to view
ColdFusion Java Applets</b>"
If no message is specified, this message displays:
<b>Browser must support Java to <br> view ColdFusion Java
Applets!</b>
Attribute Req/Opt Default Description