Detailed instructions for use are in the User's Guide.
CFML Quick Reference
Trademarks Afterburner, AppletAce, Attain, Attain Enterprise Learning System, Attain Essentials, Attain Objects for Dreamweaver, Authorware, Authorware Attain, Authorware Interactive Studio, Authorware Star, Authorware Synergy, Backstage, Backstage Designer, Backstage Desktop Studio, Backstage Enterprise Studio, Backstage Internet Studio, ColdFusion, Design in Motion, Director, Director Multimedia Studio, Doc Around the Clock, Dreamweaver, Dreamweaver Attain, Drumbeat, Drumbeat 2000, Extreme 3D, Fireworks, Flash, Fontographer, FreeHand, FreeHand Graphics Studio, Generator, Generator Developer's Studio, Generator Dynamic Graphics Server, JRun, Knowledge Objects, Knowledge Stream, Knowledge Track, Lingo, Live Effects, Macromedia, Macromedia M Logo & Design, Macromedia Flash, Macromedia Xres, Macromind, Macromind Action, MAGIC, Mediamaker, Object Authoring, Power Applets, Priority Access, Roundtrip HTML, Scriptlets, SoundEdit, ShockRave, Shockmachine, Shockwave, Shockwave Remote, Shockwave Internet Studio, Showcase, Tools to Power Your Ideas, Universal Media, Virtuoso, Web Design 101, Whirlwind and Xtra are trademarks of Macromedia, Inc. and may be registered in the United States or in other jurisdictions including internationally. Other product names, logos, designs, titles, words or phrases mentioned within this publication may be trademarks, servicemarks, or tradenames of Macromedia, Inc. or other entities and may be registered in certain jurisdictions including internationally. This product includes code licensed from RSA Data Security. This guide contains links to third-party websites that are not under the control of Macromedia, and Macromedia is not responsible for the content on any linked site. If you access a third-party website mentioned in this guide, then you do so at your own risk. Macromedia provides these links only as a convenience, and the inclusion of the link does not imply that Macromedia endorses or accepts any responsibility for the content on those third-party sites. Apple Disclaimer
APPLE COMPUTER, INC. MAKES NO WARRANTIES, EITHER EXPRESS OR IMPLIED, REGARDING THE ENCLOSED COMPUTER SOFTWARE PACKAGE, ITS MERCHANTABILITY OR ITS FITNESS FOR ANY PARTICULAR PURPOSE. THE EXCLUSION OF IMPLIED WARRANTIES IS NOT PERMITTED BY SOME STATES. THE ABOVE EXCLUSION MAY NOT APPLY TO YOU. THIS WARRANTY PROVIDES YOU WITH SPECIFIC LEGAL RIGHTS. THERE MAY BE OTHER RIGHTS THAT YOU MAY HAVE WHICH VARY FROM STATE TO STATE.
Copyright © 1999Â2003 Macromedia, Inc. All rights reserved. This manual may not be copied, photocopied, reproduced, translated, or converted to any electronic or machine-readable form in whole or in part without prior written approval of Macromedia, Inc. Part number: ZCF61M400 Project Management: Randy Nielsen Editing: Linda Adler First Edition: May 2002 Second Edition: August 2003 Macromedia, Inc. 600 Townsend St. San Francisco, CA 94103
CONTENTS
CFML tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 CFML functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 Array functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 Authentication functions . . . . . . . . . . . . . . . . . . . . . . . . . 20 Conversion functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 Date and time functions . . . . . . . . . . . . . . . . . . . . . . . . . . 20 Decision functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 Display and formatting functions . . . . . . . . . . . . . . . . . . . 22 Dynamic evaluation functions . . . . . . . . . . . . . . . . . . . . . 22 Extensibility functions . . . . . . . . . . . . . . . . . . . . . . . . . . . 22 Full-text search functions . . . . . . . . . . . . . . . . . . . . . . . . . 23 International functions . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 List functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 Mathematical functions . . . . . . . . . . . . . . . . . . . . . . . . . . 24 Other functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 Query functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 String functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 Structure functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 System functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 XML functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 ColdFusion variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 Variable scope . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 Caller scope . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 Client variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 Server variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 Application and session variables . . . . . . . . . . . . . . . . . . . 28 Custom tag variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29 Request variable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29 Form variable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29 ColdFusion tag-specific variables . . . . . . . . . . . . . . . . . . . . 29 ColdFusion query variables . . . . . . . . . . . . . . . . . . . . . . . . 30 CFCATCH variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 CFDIRECTORY variables . . . . . . . . . . . . . . . . . . . . . . . . 30 CFERROR variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 CFFILE ACTION=Upload variables . . . . . . . . . . . . . . . . 31 CFFTP error variables . . . . . . . . . . . . . . . . . . . . . . . . . . . 31 CFFTP ReturnValue variable . . . . . . . . . . . . . . . . . . . . . . 31 CFFTP query object columns . . . . . . . . . . . . . . . . . . . . . 31 CFHTTP variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 CFLDAP variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 CFPOP variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 CFQUERY and CFSTOREDPROC variables . . . . . . . . . 32 CFREGISTRY variables . . . . . . . . . . . . . . . . . . . . . . . . . . 33 CFSEARCH variables . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
CFML Quick Reference
3
Standard CGI variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 Request . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 Server . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 Client . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
4
CFML Quick Reference
CFML tags
cfabort
cfapplet
cfapplication
cfargument
cfassociate
cfbreak
cfcache
cfcase
cfcatch
Exception processing code here
cfchart
cfchartdata
cfchartseries
cfcol
cfcollection
cfcomponent
hint = "text string"> variable declarations ... ...
cfcontent
starting with a drive letter and a colon, or a forward or backward slash
6
CFML Quick Reference
cfcookie
cfdefaultcase
cfdirectory
cfdump
cfelse
HTML and CFML tags HTML and CFML tags HTML and CFML tags
cfelseif
HTML and CFML tags HTML and CFML tags HTML and CFML tags
cferror
cfexecute
...
cfexit
cffile
CFML Quick Reference
7
cfflush
cfform