In the Application.cfm page, prior to the redirect to the login page, but after validating that the session.allowedin var is 'false'. Set a session.var to the cgi.REMOTE_URI. (The user is on the page that they wanted, but the login is about to send them to the login, so you store their intent before they get bounced)
Once the person authenticates against the cfldap successfully, check to see if the session.var for cgi.REMOTE_URI exists, if so, then cflocation the user to that page, otherwise, cflocation the user to the 'secure' index page. Hope this helps, William -- William E. Seiter Have you ever read a book that changed your life? Go to: www.winninginthemargins.com Enter passkey: goldengrove Web Developer http://William.Seiter.com -----Original Message----- From: Ian Littlefair [mailto:[EMAIL PROTECTED] Sent: Friday, October 19, 2007 4:36 AM To: CF-Talk Subject: Authentication working - would like to amend I have a web site with an index page with links to secure and non-secure pages. The authentication is done via an Application.cfm page using <cfparam name="session.allowin" default="false"> with a redirect to the login form if "session.allowin neq true". The user enters a name and password into the login form whose "action" is to a checkuser.cfm template where the user's form username and form password are first validated against an ntsecurity.cfc using cfinvoke and if false are redirected back to the login form with an error message, but if not the user's details are then checked against an AD using cfldap. If true a cflocation url takes them to a "secure" index page. The scripts have been working fine for over a year and I'm loathe to fix something that aint broke but I would now like to amend it so that the user is taken to the secure url of the link they chose in the index.cfm page rather that have to choose the link again in the secureindex.cfm page once authentication has been passed. I've tried re-writing the scripts to use cflogin and using cfset FormAction="#CGI.SCRIPT_NAME#" but I just seem to be getting more and more bogged down. Any assistance would be appreciated. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| ColdFusion 8 - Build next generation apps today, with easy PDF and Ajax features - download now http://download.macromedia.com/pub/labs/coldfusion/cf8_beta_whatsnew_052907.pdf Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:291562 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

