How to use NOT EQUAL operator in cfif condition in ColdFusion

cfif - NOT EQUAL operator

cfifNOTEQUALOperator.cfm


<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>cfif NOT EQUAL operator - how to use (NOT EQUAL) operator in cfif condition</title>
    <style type="text/css">
  .divCSS
  {
   background-color:OrangeRed;
   color:White;
   font-family:Georgia, "Times New Roman", Times, serif;
   font-size:X-large;
   width:425px;
   height:70px;
   text-align:center;
   padding-top:25px;
   }
 </style>
</head>

<body>
<h2 style="color:SeaGreen; font-style:italic">coldfusion cfif tag example: how to use "NOT EQUAL" operator</h2>
<hr width="575" align="left" color="LawnGreen" />
<br />


<cfset UserID=5>

<div class="divCSS">
 <cfif UserID NOT EQUAL 2 >
        Sorry you are not allowed!
    <cfelse>
        Wellcome admin!
    </cfif>
</div>

</body>
</html>