Hi I can't get this to work.It looks for data from SQL7 table called tblUser
I've been fiddling with it but obviously missing something.
Can anyone spot the error
---------------------------------
<!DOCTYPE html public "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<TITLE>Login</TITLE>
</HEAD>
<BODY>
<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 name--->
UserName
<INPUT type="text" name="userName"><BR><!--- enter password --->
Password
<INPUT type="password" name="password"><BR>
<INPUT type="submit" value=" Login ">
</FORM></CENTER>
</BODY>
</HTML>
--------------------
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 to
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/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists