Jump to content

Registering a User problem??


This topic is 6984 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies

Hey guys!! I could use some help on this problem.

I think I have most of it but I keep getting an error message of

Record Not Found:

The specified record was not found.

here is the code I am using and it connects to a Weblayout with the Email and UNIV ID fields already present because if your Emal and and UNIV dont match the db then you cannot register.

The password is entered 2 times as you can see from the code.

What am I doing wrong? Any suggestions to better this problem??

thanx a million

matt

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<title>Student Register</title>

<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

<html>

<head>

<SCRIPT LANGUAGE="JavaScript">

<!-- Begin

function validate() {

var invalid = " "; // Invalid character is a space

var minLength = 6; // Minimum length

var pw1 = document.StudentRegister.StudentInternshipPassword.value;

var pw2 = document.StudentRegister.VerifyPassword.value;

// check for a value in both fields.

if (pw1 == '' || pw2 == '') {

alert('Please enter your password twice.');

return false;

}

// check for spaces

if (document.StudentRegister.StudentInternshipPassword.value.indexOf(invalid) > -1) {

alert("Sorry, spaces are not allowed.");

return false;

}

else {

if (pw1 != pw2) {

alert ("You did not enter the same new password twice. Please re-enter your password.");

return false;

}

else {

alert('Nice job.');

return true;

}

}

}

// End -->

</script>

</head>

<body>

<form name="StudentRegister" action="FMPro" method="post" onSubmit="return validate()">

<P><INPUT TYPE="hidden" NAME="-RecID" VALUE="[FMP-currentrecid]">

<P><INPUT TYPE="hidden" NAME="-db" VALUE="TESTCOPYStudent Table_.fp5">

<P><INPUT TYPE="hidden" NAME="-lay" VALUE="Weblayout">

<P><INPUT TYPE="hidden" NAME="-format" VALUE="portal.html">

<p>Enter your Iowa State University Email Address:

<input type="hidden" name="studentemail" value="==">

<input type="text" name="Email">

<p>Enter your University ID:

<input type="hidden" name="username" value="==">

<input type="text" name="UNIV ID">

<p>

<br>

Enter your password twice.

<br>

<p>

Password:

<input type="hidden" name="password">

<input type="password" name="StudentInternshipPassword">

<br>

Verify password:

<input type="hidden" name="password2">

<input type="password" name="VerifyPassword">

<input type="submit" name="-Edit" value="Submit">

</FORM>

</body>

</html>

Link to comment
Share on other sites

Howdy, CDML! If you post this in the CDML forums, Garry or some other JS savy folks may be able to help better, but my guess is that you are performing an -edit action before querying the db. You specify the recID using [FMP-CurrentRecID] but it has no value until a query is sent to the Web Companion.

That's only a quick glance guess, though, since I've only done a very limited amount of JS and I'm not sure what precedes this page. Sorry if I'm not paying close enough attention...

--ST

Link to comment
Share on other sites

This topic is 6984 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.