Determines whether an authenticated user belongs to any Role.
True, if the authenticated user, belongs to any Role; False, otherwise.
Security functions, Decision functions
IsUserInAnyRole()
cflogin, cfloginuser, cflogout, GetAuthUser, GetUserRoles, IsUserInRole, IsUserLoggedIn, "Securing Applications" in the ColdFusion Developer's Guide
ColdFusion 8: Added this function.
Role names are not case-sensitive.
To check if a user is in multiple roles, specify them in a comma-delimited list, such as "Admin,HR". Lists with multiple roles cannot contain spaces as separators; for example, do not use "Admin, HR".
<cfif IsUserInAnyRole() > <cfoutput>Authenticated user is in these roles: #GetUserRoles()#</cfoutput> <cfelseif > <cfoutput>Authenticated user is in no roles</cfoutput> </cfif>