
816
DEVELOPING
COLDFUSION 9 APPLICATIONS
Requesting and Presenting Information
Las
t
upda
te
d 8/5/2010
This is a cfwindow control.<br><br>
<a href="javascript:ColdFusion.navigate('windowsource.cfm','w2',
mycallBack,myerrorHandler);">Click</a> to navigate Window 2</a>
</cfwindow>
<cfwindow name="w2" title="CF Window 2" initShow=true
x=250 y=200 width="200">
This is a second cfwindow control.
</cfwindow>
<cfform>
<!--- This button only replaces the second window body with the body of the
windowsrc.cfm page. --->
<cfinput type="button" name="button" value="Simple navigate"
onClick="ColdFusion.navigate('windowsource.cfm','w2');">
<!--- This button replaces the second window body and title content. --->
<cfinput type="button" name="button2" value="Change w2 body & title"
onClick="w2_body.innerHTML='New body inner HTML';w2_title.innerHTML=
'New Title inner HTML'">
<!--- This button puts the second window title in the pod body. --->
<cfinput type="button" name="button3" value="Change pod body"
onClick="theTitle_body.innerHTML=w2_title.innerHTML;">
</cfform>
</body>
</html>
The following example shows the windowsource.cfm page:
This is markup from "windowsource.cfm"
<!--- The callback handler puts its output in the following div block. --->
<div id="callback"></div>
Using menus and toolbars
The cfmenu and cfmenuitem tags let you create vertical menus and horizontal toolbars.
Define menus and toolbars
•
Use a single
cfmenu
tag to define the general menu characteristics.
•
Create a horizontal (toolbar) menu or vertical menu by specifying a
cfmenutype
attribute value of
horizontal
or
vertical
.
•
Menus can have submenus, but only the top menu can be horizontal. All children of a horizontal menu are vertical.
•
The top-level menu shows initially, a submenu shows when the user moves the mouse over the menu root in the
parent menu.
•
Use
cfmenuitem
tags to specify individual menu items.
•
To create submenus, nest
cfmenuitem
tags. The parent tag becomes the root of the submenu.
•
All
cfmenuitem
tags, except tags for dividers, must have a
display
attribute, which defines the text to show on the
menu item, and can optionally have an
image
attribute.
•
A horizontal menu has dividers between all items. You place dividers in vertical menus by specifying a
cfmenuitem
tag with a
divider
attribute.
•
To make a menu item active, specify a
href
attribute with a URL or a JavaScript function to call when the user clicks
the menu item.
Содержание COLDFUSION 9
Страница 1: ...Developing Applications ADOBE COLDFUSION 9...