Leve Google! En de vriendelijke mens die dit gepost heeft:
I discovered during some DRK research that the
getAuthUserandisUserInRolefunctions will only work if theCFLOGINtag was encountered previously within the scope of the same request. In other words, if yourCFLOGINtag is not in your Application.cfm file, and you try to callgetAuthUserorisUserInRoleduring the scope of a request where no CFLOGIN tag was encountered, you get an empty string and false respectively. I never noticed this before because I always have myCFLOGINtag in my Application.cfm file, where it was clearly intended to go. Fortunately, a quick<cflogin/>tag before you callgetAuthUserorisUserInRolefixes the issue by making the necessary variable scope available.
En zo geschiedde. Nog beter: gewoon <cflogin/> in Application.cfm zetten. Ha!
Comments