After the login button is pressed. --------------------
Does it give you that error as soon as you go to the page, or after you hit the login button? ______________________ steve oliver atnet solutions, inc. http://www.atnetsolutions.com ---------- Original Message ---------------------------------- From: "Office" <[EMAIL PROTECTED]> Reply-To: [EMAIL PROTECTED] Date: Fri, 8 Feb 2002 10:28:23 +1300 Hi Steve yep trying to avoid using cookies. I want to pass people around the private part of the site with security set from an entry in tblUser. Mike ----------------- Doh, nevermind, your not using cookies to set the login. *takes another look ______________________ steve oliver atnet solutions, inc. http://www.atnetsolutions.com -----Original Message----- From: Steve Oliver [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 07, 2002 4:06 PM To: CF-Talk Subject: RE: Password Protection - whats wrong with this Yeah, your using cflocation, which will not set cookies. Try using <cfheader name="REFRESH" value="0; url=index.cfm"> Or you could use a meta tag, or a javascript redirection. ______________________ steve oliver atnet solutions, inc. http://www.atnetsolutions.com Oops! I've taken out the HTML so it won't appear as a web page Mike Hi I can't get this to work.It looks for data from SQL7 table called tblUse r I've been fiddling with it but obviously missing something. Can anyone spot the error --------------------------------- <CFIF IsDefined("URL.Login")><!--- ---> <CFQUERY name="getUser" datasource="CFSQL"> SELECT ID, Password FROM tblUser WHERE ID='#Form.userName#' AND password='#Form.password#' </CFQUERY> <!--- ---> <CFIF getUser.RecordCount GT 0> <CFSET SESSION.loggedIn="yes"> <CFLOCATION url="index.cfm"> <CFELSE> <CFLOCATION url="login.cfm?failed=yes"> </CFIF> </CFIF> <CFIF IsDefined("URL.failed")> <CFSET errMsg="Login Failed, Please Try Again"> <CFELSEIF IsDefined("URL.notLoggedIn")> <CFSET errMsg="User Not Logged In"> <CFELSE> <CFSET errMsg="Please Login Below"> </CFIF> <CENTER><BR><H3><B>Welcome to NZERN Members Website</B></H3><BR><H4> <!--- gives error message on web page ---> <CFOUTPUT> #errMsg# </CFOUTPUT> </H4><BR><BR><!--- form to login ---> <FORM action="login.cfm?login=yes" method="post"><!--- enter user na me---> UserName <INPUT type="text" name="userName"><BR><!--- enter password ---> Password <INPUT type="password" name="password"><BR> <INPUT type="submit" value=" Login "> -------------------- Error Diagnostic Information An error occurred while evaluating the expression: #Form.userName# Error near line 23, column 18. --------------------------------------------------------------------------- - ---- Error resolving parameter FORM.USERNAME The specified form field cannot be found. This problem is very likely due t o the fact that you have misspelled the form field name. The error occurred while processing an element with a general identifier of (#Form.userName#), occupying document position (23:17) to (23:31). Date/Time: 02/08/02 09:55:00 Browser: Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0) Remote Address: 210.86.52.9 Query String: login=yes ------------------------------------------- thanks in advance for any help (I'm a newbee) Mike ---------------------------------------------------- NZERN Mail: PO Box 9000, Christchurch (03) 338-5451 E-mail: [EMAIL PROTECTED] http://www.bush.org.nz ---------------------------------------------------- ______________________________________________________________________ Get Your Own Dedicated Windows 2000 Server PIII 800 / 256 MB RAM / 40 GB HD / 20 GB MO/XFER Instant Activation · $99/Month · Free Setup http://www.pennyhost.com/redirect.cfm?adcode=coldfusionb FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists