
267
DEVELOPING
COLDFUSION 9 APPLICATIONS
Developing CFML Applications
Las
t
upda
te
d 8/5/2010
Supported tags
Limitations
•
The following tags are not supported:
•
cfpdf
•
cfpdfform
•
The following functions are not supported:
•
FileSetAccessMode
that sets attributes of a file in Linux/UNIX
•
FilesSetAttribute
that sets the attributes of a file in Windows
•
cfzip
does not accept Amazon S3 object as source.
•
When S3 object is used as output for
outputfile
attribute of
cfexecute
tag, it results in an error
Timeout
period expired without completion of <exe>
. It also results in a NullPointerException at server console.
•
To use the function
fileMove,
the source and destination objects must have the same bucket name. That is,
you cannot move Amazon S3 objects across buckets or to other file systems.
Working with in-memory files
Memory-based virtual file system speeds up the processing of transient data. In-memory files are not written to disk
and are saved on RAM. They function similar to disk files but perform faster.
In ColdFusion, in-memory files help you to simplify the execution of dynamic code. In-memory files are supported
across almost all tags and functions that take file or directory as input or output.
You use in-memory files in the same manner as files on disk, but with a prefix
ram:///
to indicate that they reside on
RAM. For example,
ram:///a/b/dynamic.cfm.
Writing and executing dynamic CFM files
The following syntax explains how to write CFM data in to an in-memory file:
<cffile action="write" output="#cfml#"
file="ram:///filename.cfm"/>
The following sample syntax explains how to use the in-memory CFM file:
•
For tags that take logical path, define mapping in Administrator. Execute in-memory CFM pages using the
cfinclude
tag:
<cfinclude template="/inmemory/filename.cfm">
Create a mapping for
ram:///
so that it can be used in the tags. In this example,
/inmemory
is the mapping that
points to
ram:///
.
•
For tags that take absolute path, specify the syntax as provided in the following example:
<cffile action="append" file="ram:///a/b/dynamic.cfm" output="I'm appending">
Note:
You cannot have Application.cfm as an in-memory file. If you have one, it is ignored.
directoryExists
directoryList
imageNew
imageRead
imageWrite
imageWriteBase64
isImageFile
isPDFFile
All
cffile
actions
All
cfdirectory
actions
(except rename)
cfdocument
cffeed
cfftp
cfimage
cfloop
All
cfimage
actions