Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Simple: Login error?

Participant ,
Apr 06, 2008 Apr 06, 2008
I use the DW Restrict Access behavior feature to create my login page. I hook it to a MS Access db, username and password table. (client required Access).

It works well, except when the viewer's last name is hyphenated (ex: Jones-Laurel), and then the login denies, when it shouldn't. I assume this has something to do with the server trying to subtract these names?

Here is the login code:

<cfset MM_redirectLoginSuccess="memberaccess/index2.cfm">
<cfset MM_redirectLoginFailed="login2.cfm?error=1">
<cfquery name="MM_rsUser" datasource="aptahpa">
SELECT id,last_name,levels FROM hpamembers WHERE id=
<cfqueryparam value="#FORM.username#">
AND last_name=
<cfqueryparam value="#FORM.password#" maxlength="255">
</cfquery>


What can I do to prevent this?

Many thanks,
Stephen
265
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Participant ,
Apr 07, 2008 Apr 07, 2008
LATEST
sbsmithfl, wrap the code between <cftry><cfcatch> and then <cfdump> the actual error to see what cf is trying to do. I would also use the CFSQLType attribute with your cfqueryparam tags. Always a good idea...
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources