User Guide
cftimer 421
cftimer
Description
Displays execution time for a specified section of CFML code. ColdFusion MX displays the
timing information along with any output produced by the timed code.
Note: To permit this tag to execute, you must enable the Timer Information option under Debugging
Settings in the ColdFusion MX Administrator.
Category
Debugging tags
Syntax
<cftimer
label= "text"
type = "inline" or "outline" or "comment" or "debug" >
CFML statement(s)
</cftimer>
See also
cfdump
, cftrace; Chapter 18, “Debugging and Troubleshooting Applications” in ColdFusion
MX Developer’s Guide
History
ColdFusion MX 7: Added this tag.
Attributes
Usage
Use this tag to determine how long it takes for a block of code to execute. You can nest cftimer
tags.
This tag is useful for debugging CFML code during application development. In production, you
can leave
cftimer tags in your code as long as you have disabled the debugging option in the
ColdFusion MX Administrator.
Attribute Req/Opt Default Description
label Optional " " Label to display with timing information.
type Optional debug • inline: displays timing information inline, following the
resulting HTML.
• outline: displays timing information and also displays a line
around the output produced by the timed code. The browser
must support the FIELDSET tag to display the outline.
• comment: displays timing information in an HTML comment
in the format <!-- label: elapsed-time ms -->. The default label
is
cftimer.
• debug: displays timing information in the debug output
under the heading CFTimer Times.