The cfsetting
tag lets you specify the following page processing attributes that you might want to apply to all pages in your application:
Attribute | Use |
---|---|
showDebugOutput |
Specifies whether to show debugging output. This setting cannot enable debugging if it is disabled in the ColdFusion MX Administrator. However, this option can ensure that debugging output is not displayed, even if the Administrator enables it. |
requestTimeout |
Specifies the page request time-out. If ColdFusion cannot complete processing a page within the time-out period, it generates an error. This setting overrides the setting in the ColdFusion MX Administrator. You can use this setting to increase the page time-out if your application or page frequently accesses external resources that might be particularly slow, such as external LDAP servers or web services providers. |
enableCFOutputOnly |
Disables output of text that is not included inside |
Often, you use the cfsetting
tag on individual pages, but you can also use it in your Application.cfc file. For example, you might use it in multi-application environment to override the ColdFusion MX Administrator settings in one application.
You can put an application-wide cfsetting
tag in the component initialization code, normally following the This scope application property settings, as the following example shows:
<cfcomponent> <cfscript> This.name="MyAppl"; This.clientmanagement="True"; This.loginstorage="Session" ; This.sessionmanagement="True" ; This.sessiontimeout=CreateTimeSpan(0,0,1,0); </cfscript> <cfsetting showdebugoutput="No" enablecfoutputonly="No">
The cfsetting
tag in this example affects all pages in an application. You can override the application-wide settings in the event methods, such as onRequestStart
, or on individual ColdFusion pages.