Controls various aspects of page processing, such as the output of HTML code in pages. One benefit of this option is managing whitespace that can occur in output pages served by ColdFusion.
<cfsetting enableCFoutputOnly = "Yes" or "No" showDebugOutput = "Yes" or "No" catchExceptionsByPattern = "Yes" or "No">
cfcache,
cfflush,
cfheader,
cfhtmlhead,
cfinclude,
cfsilent
Note Structured exception handling introduces a subtle upward incompatibility. In ColdFusion 4.0.x, an exception was handled by the first |
When nesting cfsetting
tags, you must match each enableCFoutputOnly = "Yes"
setting with an enableCFoutputOnly = "No"
setting for ordinary HTML text to be visible to a user. For example, if you have five enableCFoutputOnly = "Yes"
statements, you must also have five corresponding enableCFoutputOnly = "No"
statements for HTML text to be displayed again.
If at any point the output of plain HTML is enabled (no matter how many enableCFoutputOnly = "No"
statements have been processed) the first enableCFoutputOnly = "Yes"
statement blocks output.
... <cfsetting enableCFoutputOnly = "Yes"> This text is not shown <cfsetting enableCFoutputOnly = "No"> <P>This text is shown <cfsetting enableCFoutputOnly = "Yes"> <cfoutput> <P>Text within cfoutput is always shown </cfoutput> <cfsetting enableCFoutputOnly = "No"> <cfoutput> <P>Text within cfoutput is always shown </cfoutput> </body> </html>