Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - what’s wrong with this code..?
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

what’s wrong with this code..?

 Post Reply Post Reply Page  <12
Author
Awangku View Drop Down
Groupie
Groupie


Joined: 15 November 2001
Location: Malaysia
Status: Offline
Points: 70
Post Options Post Options   Thanks (0) Thanks(0)   Quote Awangku Quote  Post ReplyReply Direct Link To This Post Posted: 19 May 2003 at 2:08am

If you really have a look at the codes, you will see that you will always get the Invalid Username/Password message when you enter something in the username box.

Put the word ELSE before the Response.Write line. Something like below:

If NOT strUsername = "" Then
  .....
Else
  Response.Write("<script language=""JavaScript"">")
  .....
End If

See whether it works or not.

Back to Top
fernan82 View Drop Down
Mod Builder Group
Mod Builder Group
Avatar

Joined: 17 November 2002
Location: United States
Status: Offline
Points: 362
Post Options Post Options   Thanks (0) Thanks(0)   Quote fernan82 Quote  Post ReplyReply Direct Link To This Post Posted: 19 May 2003 at 5:17pm
Originally posted by Awangku Awangku wrote:

If you really have a look at the codes, you will see that you will always get the Invalid Username/Password message when you enter something in the username box.

Put the word ELSE before the Response.Write line. Something like below:

If NOT strUsername = "" Then
  .....
Else
  Response.Write("<script language=""JavaScript"">")
  .....
End If

See whether it works or not.

Negative, if you really have a look at the code there's a response.redirect before the javascript so if the password is correct the user will be redirected before it gets to the javascript, the If NOT strUsername = "" Then only verifies that the form has been entered so if i do as you said then it would bring that pop-up all the time!



Edited by fernan82
FeRnAN
Back to Top
 Post Reply Post Reply Page  <12

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.