O'Reilly logo

Adobe ColdFusion 8 Web Application Construction Kit, Volume 1: Getting Started by Charlie Arehart, Raymond Camden, Ben Forta

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Using getAuthUser() in Your Application Pages

Once you save Listing 23.7 as a file named Application.cfc, users will be forced to log in whenever they visit any of the pages in that folder (or its subfolders). However, the order history pages that were created above will no longer work, since they rely on the SESSION.auth variables populated by the homegrown login framework. A few changes must be made to allow the order history pages with the <cflogin> framework. Basically, this just means referring to the value returned by getAuthUser() to get the user’s ID and first name, rather than using SESSION.auth.contactID and SESSION.auth.firstName. Listing 23.8 shows the new version of the order history template.

Listing 23.8. OrderHistory3.cfm—Using ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required