Railo 4.2 Reference
Choose a tag:

Tag <CFLOG>

Writes a message to a log file.

Body

This tag can't have a body.

Example

	<cflog
		[application="boolean"]
		[async="boolean"]
		[charset="string"]
		[date="boolean"]
		[exception="any"]
		[file="string"]
		[log="string"]
		[text="string"]
		[thread="boolean"]
		[time="boolean"]
		[type="string"]>
	
This tag is also supported within cfscript
	<cfscript>
		log
		[application="boolean"]
		[async="boolean"]
		[charset="string"]
		[date="boolean"]
		[exception="any"]
		[file="string"]
		[log="string"]
		[text="string"]
		[thread="boolean"]
		[time="boolean"]
		[type="string"];
	</cfscript>

Attributes

The attributes for this tag are fixed. Except for the following attributes no other attributes are allowed.
Name Type Required Description
application boolean No Specifies whether to log the application name if one has been specified in a cfapplication tag. 
async boolean No only works in combination with the attribute "file", if set to true the file is written in a separate thread. 
charset string No Character set name for the file contents. 
date boolean No This Attribute is deprecated 
exception any No The message text to log. 
file string No This Attribute is deprecated 
log string No If you omit the file attribute, specifies the log in which to write the message.
this references can be defined in the Railo Administrator.
Ignored if you specify a file attribute. 
text string No a exception to log. 
thread boolean No This Attribute is deprecated 
time boolean No This Attribute is deprecated 
type string No the following is the log type (level) in decreasing order of severity:
  • fatal: Severe errors that cause premature termination.
  • error: Other runtime errors or unexpected conditions.
  • warn,warning: Use of deprecated APIs, poor use of API, 'almost' errors, other runtime situations that are undesirable or unexpected, but not necessarily "wrong".
  • info,information (default): Interesting runtime events.
  • debug: Detailed information on the flow through the system.
  • trace:Most detailed information.