Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - Login not working correctly...
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Login not working correctly...

 Post Reply Post Reply
Author
jrockfl View Drop Down
Newbie
Newbie


Joined: 03 February 2003
Location: United States
Status: Offline
Points: 28
Post Options Post Options   Thanks (0) Thanks(0)   Quote jrockfl Quote  Post ReplyReply Direct Link To This Post Topic: Login not working correctly...
    Posted: 19 July 2003 at 5:15pm

When I try to login, it keeps saying my password is incorrect. I am trying to set the userid as a session variable. This field is autonumber in an access database. Here is the code I am using. I have added one user to the database. Any ideas?

<%
 Response.Buffer = True
 Dim objConn, objRS
 Session.Contents("userid") = ""
 Set objConn = Server.CreateObject("ADODB.Connection")
 objConn.Open "DSN=survey"
 Set objRS = objConn.Execute("SELECT * FROM tblusers WHERE username = '" & _
  Request.Form("username") & "'")
 If Not objRS.EOF Then
  If objRS(1) = Request.Form("password") Then
  Session.Contents("userid") = objRS(2)
  Response.Redirect "menu.asp"
  Else
  Response.Write "Sorry, but the password that you entered is incorrect."
  End If
 Else
  Response.Write "Sorry, that username does not exist."
 End If
 objRS.Close
 Set objRS = Nothing
 objConn.Close
 Set objConn = Nothing
%>

 

Back to Top
jrockfl View Drop Down
Newbie
Newbie


Joined: 03 February 2003
Location: United States
Status: Offline
Points: 28
Post Options Post Options   Thanks (0) Thanks(0)   Quote jrockfl Quote  Post ReplyReply Direct Link To This Post Posted: 19 July 2003 at 7:00pm

in the database my username = jason and my password = jason

It will let me login if my password = Jason with a capital "J"

Any ideas to correct this?

Back to Top
jrockfl View Drop Down
Newbie
Newbie


Joined: 03 February 2003
Location: United States
Status: Offline
Points: 28
Post Options Post Options   Thanks (0) Thanks(0)   Quote jrockfl Quote  Post ReplyReply Direct Link To This Post Posted: 19 July 2003 at 7:06pm
Ok..its not pullling querying the password field in the db, it is querying from firstname instead
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.