Has anyone had any luck implimenting this? I copied this code directly from
the "Developing ColdFusionMX Applications with CFML" book that Macromedia
includes with CFMX into an Application.cfm template:
<cfapplication name="Test" clientmanagement="yes"/>
<cflogin>
<cfif IsDefined( "cflogin" )>
<cfif cflogin.name eq "admin" and cflogin.password eq "p1">
<cfset roles = "user,admin">
<cfelseif cflogin.name eq "user" and cflogin.password eq "p2">
<cfset roles = "user">
</cfif>
</cfif>
<cfif IsDefined( "roles" )>
<cfloginuser name="#cflogin.name#" password="#cflogin.password#"
roles="#roles#">
<cfelse>
<!--- User has not logged in or authentication failed - send 401 --->
<cfsetting enablecfoutputonly="yes" showdebugoutput="no">
<cfheader statuscode="401">
<cfheader name="WWW-Authenticate" value="Basic realm=""MySecurity""">
<cfoutput>Not authorized</cfoutput>
<cfabort>
</cfif>
</cflogin>
The login box pops up every time, but it won't accept the correct
password.... Just pops up the login box again for 2 more times then I get a
browser error about not being authorized.
CFMX, Updater 3, tried on Windows XP Pro, Windows 2000 Server... same
results.
Jonathan
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription:
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Your ad could be here. Monies from ads go to support these lists and provide more
resources for the community.
http://www.fusionauthority.com/ads.cfm
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4