Popular Searches: FrontPage Hosting | FrontPage Templates | FrontPage Training | Free FrontPage

Password validation error that makes no sense!   Logged in as: Guest
  Printable Version
All Forums >>FrontPage Specific Issues >>FrontPage 2003 >> Page: [1]
Name:
Message<< Newer Topic  Older Topic >>

RobinC

 

Posts: 5
Member since: 8/17/2008
 

Password validation error that makes... 

I have made a very brief login form, with validation required for a Login ID and a Password. However, if the login and/or password are not entered correctly, an error message (titled Windows Internet Explorer) pops up and says, "Please enter a value equal to [password]" in the Password field ... and it actually tells you exactly what the password is! I have it configured to go to an error page in the case of incorrectly entered information, but all it does is flash this same error message (separate window) and stay on the same page. I also have it configured to go to the appropriate page if the correct info is entered and that DOES work.

I have done some pretty incredible sites with good ol' Front Page, but this is one thing that I can't find a work-around for. Any help will be VERY appreciated!

Thanks so much ...

Robin in Charlotte, NC

www.robincastaldi.com
  Report Abuse |  Date: 8/17/2008 10:59:45 PM

Rick_E

 

Posts: 3771
Member since: 2/14/2004
 

RE: Password validation error that m... (in reply to RobinC

The FrontPage form is likely the wrong tool to solve your login needs. Depending on your requirements, number of user accounts, and hosting system (Windows or Linux),you may want to password protect a folder using your web host control panel, or choose a more advanced login system.


_____________________________

All the best, Rick E

Search Microsoft KB for error msgs
http://support.microsoft.com/search/default.aspx?catalog=LCID%3D1033&spid=919&adv=1
  Report Abuse |  Date: 8/18/2008 5:15:57 AM

RobinC

 

Posts: 5
Member since: 8/17/2008
 

RE: Password validation error that m... (in reply to RobinC

Hey, Rick ...

Thanks so much for your reply. I know this is probably very simple, but I am just at a loss to figure out how to do it. The details are this: it's a very small site to give buyers of a stalled condo project access to the latest news and updates. There is only one login ID and one password that will be given to everyone who has prepurchased a unit. So there isn't a need for a big database of logins and passwords (which I don't know how to do anyway). I have the site hosted on GoDaddy. Any help or direction you can give me on how to accomplish this will be greatly appreciated.

Best wishes,
Robin
  Report Abuse |  Date: 8/18/2008 8:32:48 AM

TexasWebDevelopers

Posts: 7039
Member since: 9/24/2002
From: USA

RE: Password validation error that m... (in reply to RobinC

You can password protect your pages easily with ASP and a few lines of code at the top of the page:
http://www.texaswebdevelopers.com/examples/login_script.asp


_____________________________



FrontPageTools.com:Templates, Tools and Training support this forum
  Report Abuse |  Date: 8/18/2008 11:16:51 AM

RobinC

 

Posts: 5
Member since: 8/17/2008
 

RE: Password validation error that m... (in reply to RobinC

Hey, TWD ...

Thanks so much for the response. I'm getting confused with where I should change things in the scripts. Would you mind looking at my code and telling me where I'm going wrong? I'm just not very experienced with scripts.

The actual site is: http://www.210update.com. The current login ID is: condobuyer; the current password is: scrabble. I want a successful login to redirect to http://www.210update.com/update.htm.

INDEX PAGE CODE:

<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>210 Trade Information</title>
</head>

<body background="Bkgd-dbl.gif" topmargin="0" leftmargin="0" rightmargin="0" bottommargin="0">

<div align="center">
<table border="0" width="876" cellspacing="0" cellpadding="0" id="table1">
<tr>
<td>
<p align="center">
<img border="0" src="210Trade-Heading.jpg" width="876" height="327"></td>
</tr>
</table>
</div>
<div align="center">
<table border="0" width="691" cellspacing="0" cellpadding="0" id="table2">
<tr>
<td align="center">
<img border="0" src="210Trade-Login-1.gif" width="691" height="84"></td>
</tr>
<tr>
<td align="center" background="210Trade-Bk-Table.gif" width="691" height="10"> <div align="center">
 <%
If Ucase(Request.querystring("UserInit"))= "condobuyer" and Ucase(Request.querystring("Password"))="scrabble" Then
Session("accessok")=true
Response.redirect "updates.com"
Else
If Ucase(Request.querystring("UserInit"))<> "" or Ucase(Request.querystring("Password"))<>"" Then
Session("accessok")=false
TmpStr="Sorry !, wrong username and password"
End if
End If
%>
<html>
<head>
<title>210 Trade Information</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<base target="_self">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<form method="GET" target="_self"action="updates.com">
<table border="0" cellpadding="4" cellspacing="0"
width="350">
<tr bgcolor="#FFFFFF">
<td colspan="2" height="30">
<p align="center"><b><font size="2" face="Trebuchet MS">User ID:  </font></b>  
<input type="text" name="UserInit" size="20">
</td>
</tr>
<tr bgcolor="#FFFFFF">
<td colspan="2" height="30">
<p align="center"><font face="Trebuchet MS" size="2"><b>Password: </b></font>
 <input type="password" name="Password" size="20">
</td>
</tr>
<tr bgcolor="#FFFFFF">
<td align="center" colspan="2">
<input type="submit" value="Login" name="submit"
title="Login" onMouseOver="window.status=this.title" onMouseOut="window.status=''" style="font-size: 10pt; font-family: Trebuchet MS">
</td>
</tr>
<tr>
<td align="center" colspan="2" bgcolor="#FFFFFF"><%=TmpStr%></td>
</tr>
</table>
</form>
</body>
</html>
</div>
</td>
</tr>
<tr>
<td align="center">
<img border="0" src="210Trade-level-3.gif" width="691" height="55"></td>
</tr>
</table>
</div>

</body>

</html>

-------------------------------------------------------------

And how should I configure the script at the top of the updates.htm page? Or do I need to have it redirect to an .asp page? I tried that but didn't get it to work.

Thanks so much!!!

Robin
  Report Abuse |  Date: 8/18/2008 1:51:08 PM

TexasWebDevelopers

Posts: 7039
Member since: 9/24/2002
From: USA

RE: Password validation error that m... (in reply to RobinC

You code is very messed up.
The page should have the format:
<html>
<head>
</head>
<body>
</body>
</html>
You have multiple instances of these tags in the code.

This goes at the top of the page above the <html>
<%
If Ucase(Request.querystring("UserInit"))= "condobuyer" and Ucase(Request.querystring("Password"))="scrabble" Then
Session("accessok")=true
Response.redirect "updates.com"
Else
If Ucase(Request.querystring("UserInit"))<> "" or Ucase(Request.querystring("Password"))<>"" Then
Session("accessok")=false
TmpStr="Sorry !, wrong username and password"
End if
End If
%>

The form goes in between the <body> tags:

<form method="GET" target="_self"action="updates.com">
<table border="0" cellpadding="4" cellspacing="0"
width="350">
<tr bgcolor="#FFFFFF">
<td colspan="2" height="30">
<p align="center"><b><font size="2" face="Trebuchet MS">User ID: </font></b>
<input type="text" name="UserInit" size="20">
</td>
</tr>
<tr bgcolor="#FFFFFF">
<td colspan="2" height="30">
<p align="center"><font face="Trebuchet MS" size="2"><b>Password: </b></font>
<input type="password" name="Password" size="20">
</td>
</tr>
<tr bgcolor="#FFFFFF">
<td align="center" colspan="2">
<input type="submit" value="Login" name="submit"
title="Login" onMouseOver="window.status=this.title" onMouseOut="window.status=''" style="font-size: 10pt; font-family: Trebuchet MS">
</td>
</tr>
<tr>
<td align="center" colspan="2" bgcolor="#FFFFFF"><%=TmpStr%></td>
</tr>
</table>
</form>


_____________________________



FrontPageTools.com:Templates, Tools and Training support this forum
  Report Abuse |  Date: 8/18/2008 3:36:18 PM

RobinC

 

Posts: 5
Member since: 8/17/2008
 

RE: Password validation error that m... (in reply to RobinC

Thank you! I knew that I had totally screwed up the code. Thanks for making sense of it for me. It's a tremendous help, and I will work on this with your code.

One other question, do I put a page name on the Protected Page code or does it need to refer to an .asp file . . . " . . . Response.redirect "login_script.asp"]?

Thanks!

Robin
  Report Abuse |  Date: 8/18/2008 4:08:23 PM

TexasWebDevelopers

Posts: 7039
Member since: 9/24/2002
From: USA

RE: Password validation error that m... (in reply to RobinC

OK let me see if I can explain this more clearly:
At the very top of every page you want to protect--on line 1 of the code view--put this code:
<%
If Session("accessok")=false then
Response.redirect "twdlogin.asp"
End if
%>
This bit of code looks for a session variable named AccessOK and if it sees the session is "true" it lets you view the page. If the session is "false" then it will redirect the user to the login page (twdlogin.asp in this case).

All of the protected pages need to have the suffix .asp not .htm or .html
Just change the ending--nothing bad will happen but you may have to re-do your links to those pages.

The code we were looking at before was the login page code (twdlogin.asp but you can name it anything you want to as long as the redirect on the protected pages are pointed back to the login page.

On the login page you put this at the very top of the page (code view line 1):
<%
If Ucase(Request.querystring("UserInit"))= "ADMIN" and Ucase(Request.querystring("Password"))= "ADMIN" Then
Session("accessok")=true
Response.redirect "login_success.asp"
Else
If Ucase(Request.querystring("UserInit"))<> "" or Ucase(Request.querystring("Password"))<> "" Then
Session("accessok")=false
TmpStr="Sorry !, wrong username and password"
End if
End If
%>
Here is where you set the username and password --in ALL CAPS -- (ADMIN/ADMIN is the example above). The code reads like this
IF the user types in the correct username and password THEN redirect to login_success.asp (or whatever page you want to designate).
Otherwise, the session AccessOK is false and the user needs to try again to enter a username and password. What is cool is that once logged in, the user will be able view ALL of the pages that have been protected (they don't have to login to each and every page) because their browser session will be AccessOK. If there is no browser activity after 20 minutes (the typical browser session on a server) they will be logged out automatically.

The form code, stripped down, is this, and obviously goes on the twdlogin.asp page.

<form method="GET" target="_self" action="twdlogin.asp">
Username <input type="text" name="UserInit" size="20"><br>
Password <input type="password" name="Password" size="20"><br>
<input type="submit" value="Login" name="submit" title="Login"><br>
<%=TmpStr%>
</form>


< Message edited by TexasWebDevelopers -- 8/18/2008 4:46:06 PM >



_____________________________



FrontPageTools.com:Templates, Tools and Training support this forum
  Report Abuse |  Date: 8/18/2008 4:44:47 PM

RobinC

 

Posts: 5
Member since: 8/17/2008
 

RE: Password validation error that m... (in reply to RobinC

Hey, TWD ...

I can't tell you how incredibly much I appreciate your sainted patience with me and all your help! I finally got it working well ... I realized that I needed to make the login page .asp as well, so I put a token entry page as the html homepage and it's all working perfectly. I learned alot and am saving all of your great instructions. I've learned how to make some pretty creative sites, but my big weakness is script. You kept me from jumping off a bridge ... thanks so much!

Best wishes,
Robin

www.robincastaldi.com
  Report Abuse |  Date: 8/18/2008 10:43:57 PM
Page:   [1]
All Forums >>FrontPage Specific Issues >>FrontPage 2003 >> Page: [1]
Jump to:

New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts



Forum Software powered by ASP Playground Advanced Edition 2.0.5
Copyright © 2000 - 2003 ASPPlayground.NET

0.0625