A container for user login and authentication code. ColdFusion checks the user-provided ID and password against a data source, LDAP directory, or other repository of login identification. Used with cfloginuser tag.
<cflogin
idletimeout = "value"
applicationToken = "token"
cookieDomain = "domain"
...
<cfloginuser
name = "name"
password = "password-string"
roles = "roles">
...>
</cflogin>
New in ColdFusion MX: This tag is new.
The body of this tag executes only if there is no logged-in user. When using application-based security, you put code in the body of the cflogin tag to check the user-provided ID and password against a data source, LDAP directory, or other repository of login identification. The body must include a cfloginuser tag to establish the authenticated user's identity in ColdFusion.
The following example shows a simple authentication. This code is typically in the application.cfm page.
<cflogin>
<cfloginuser
name = "foo"
password ="bar"
roles = "admin">
</cflogin>
<cfoutput>Authorized user: #getAuthUser()#</cfoutput>
<cflogout>
<cfoutput>Authorized user: #getAuthUser()#</cfoutput>
ColdFusion 9 | ColdFusion 8 | ColdFusion MX 7 | ColdFusion MX 6.1 | ColdFusion MX | Forums | Developer Center | Bug Reporting
Version 6
Comments are no longer accepted for ColdFusion MX. ColdFusion 8 is the current version.
RSS feed | Send me an e-mail when comments are added to this page | Comment Report
Current page: http://livedocs.adobe.com/coldfusion/6/CFML_Reference/Tags-pt169.htm
Comments
Jon(Xnext) said on Aug 28, 2002 at 4:44 PM : carehart@systemanage said on Sep 14, 2002 at 8:11 PM : pir2 said on Oct 1, 2002 at 10:58 AM : rnielsen said on Mar 18, 2003 at 11:24 AM : No screen name said on Oct 17, 2003 at 9:33 PM : No screen name said on Jan 11, 2004 at 3:56 PM : No screen name said on Jul 27, 2004 at 7:45 PM : mihlf said on Aug 24, 2004 at 7:48 AM : NetbasicsNL said on May 19, 2005 at 4:54 AM : NetbasicsNL said on May 31, 2005 at 11:01 AM : No screen name said on Jun 27, 2005 at 3:24 AM :