Used with cfelse and cfelseif, cfif lets you create simple and compound conditional statements in CFML. The value in the cfif tag can be any expression.

This tag cannot have a body.

This tag is also supported within <cfscript>

This tag does not use any attributes.



```lucee+trycf <cfif isArray(SERVER)>

//script format numb=1 if(numb gt 1){ writeOutput("It is greater than 1 "); }else{ writeOutput("It is not greater than 1 "); } ```

See also