Reply to topic
CFLogin question!!!
Ennio


Joined: 17 Nov 2006
Posts: 105
Location: Scotch Plains, NJ
Reply with quote
This new website that I'm developing is going to use CFLogin for the authentication, but my question is, how can I make some exception to the pages that does not require authentication?

I have the following tag in the application.cfm that calls the login page.

Code:

<cflogin idletimeout="1800">   

   <cfif CGI.QUERY_STRING IS "">       
        <cfset FormAction = #CGI.SCRIPT_NAME#>   
    <cfelse>       
        <cfset FormAction = "#CGI.SCRIPT_NAME#?#CGI.QUERY_STRING#">   
    </cfif>
   
   <cfif NOT (IsDefined ("Form.txtEmail") AND IsDefined ("Form.txtPWD"))>       
       <cfinclude template="login.cfm">       
        <cfabort>   
   <cfelse>
      <cfscript>
         qryLogin = mjObj.LoginUser(#Form.txtEmail#, #Form.txtPWD#);
      </cfscript>   
       
      <cfif qryLogin.RecordCount EQ '1'>           
           <cfloginuser name="#qryLogin.emp_email#" password="#qryLogin.emp_password#" roles="default">
      <cfelse>           
         <cfset Invalid = "Yes">           
            <cfinclude template="login.cfm">           
            <cfabort>       
      </cfif>           
   </cfif>   
</cflogin>


I have a folder and a couple of other pages that I need access before the user logs in.
nathacof
Forum Admin

Joined: 24 Oct 2006
Posts: 192
Location: Dover, DE
Reply with quote
Use a cfswitch, and the REQUEST_URI ?

http://livedocs.adobe.com/coldfusion/8/Tags_r-s_23.html
CFLogin question!!!
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT  
Page 1 of 1  

  
  
 Reply to topic