• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

CFIF

CFIF

<cfif expression> 
         HTML and CFML tags 
<cfelseif expression> 
         HTML and CFML tags 
<cfelse> 
         HTML and CFML tags 
</cfif> 

Description

This tag is used to create conditional logic within ColdFusion. It tests a condition such as an expression and then returns true or false. If True, then the code within the tag is executed; if false, then the code within the tag is ignored. Can also be used with the CFELSE and CFELSEIF tags. This tag has no attributes but can include multiple conditions, such as:


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint