PC Review


Reply
Thread Tools Rate Thread

compare two fileds for confirmation

 
 
=?Utf-8?B?UXJ5c3RlbXM=?=
Guest
Posts: n/a
 
      30th Jun 2005
I was trying to get two inputs like pwd and compare just for confirmation
while working in form environment. Can somebody tell me what I need to do? I
intend to save the result in MS access dbs
Thanks
--
QRS
 
Reply With Quote
 
 
 
 
Andrew Murray
Guest
Posts: n/a
 
      1st Jul 2005
The form validation in Frontpage doesn't seem to allow what you want to do -
I had the same problem, and found this script below on this site:
http://javascript.internet.com

In the <form> tag, add this bit of javascript exactly as written below:

onSubmit="return checkPw(this)"


So when user clicks the submit button the script checks the two password
fields are the same, else returns an error, and asks for input again.
Insert this script below into the <body> section immediately below the body
tag, copy and paste into notepad first; then copy into the code view of your
web site.

<SCRIPT LANGUAGE="JavaScript">
<!-- Original: Carey Walker ((E-Mail Removed)) -->

<!-- This script and many more are available free online at -->
<!-- The JavaScript Source!! http://javascript.internet.com -->

<!-- Begin
function checkPw(form) {
pw1 = form.pw1.value;
pw2 = form.pw2.value;

if (pw1 != pw2) {
alert ("\nYou did not enter the same new password twice. Please re-enter
your password.")
return false;
}
else return true;
}
// End -->
</script>



"Qrystems" <(E-Mail Removed)> wrote in message
news:3D58F756-6C89-469C-A059-(E-Mail Removed)...
>I was trying to get two inputs like pwd and compare just for confirmation
> while working in form environment. Can somebody tell me what I need to do?
> I
> intend to save the result in MS access dbs
> Thanks
> --
> QRS



 
Reply With Quote
 
=?Utf-8?B?UXJ5c3RlbXM=?=
Guest
Posts: n/a
 
      1st Jul 2005
Thanks Mr. Murray
But what is pw1 and pw2. are they referring to the field names on the form?

--
QRS


"Andrew Murray" wrote:

> The form validation in Frontpage doesn't seem to allow what you want to do -
> I had the same problem, and found this script below on this site:
> http://javascript.internet.com
>
> In the <form> tag, add this bit of javascript exactly as written below:
>
> onSubmit="return checkPw(this)"
>
>
> So when user clicks the submit button the script checks the two password
> fields are the same, else returns an error, and asks for input again.
> Insert this script below into the <body> section immediately below the body
> tag, copy and paste into notepad first; then copy into the code view of your
> web site.
>
> <SCRIPT LANGUAGE="JavaScript">
> <!-- Original: Carey Walker ((E-Mail Removed)) -->
>
> <!-- This script and many more are available free online at -->
> <!-- The JavaScript Source!! http://javascript.internet.com -->
>
> <!-- Begin
> function checkPw(form) {
> pw1 = form.pw1.value;
> pw2 = form.pw2.value;
>
> if (pw1 != pw2) {
> alert ("\nYou did not enter the same new password twice. Please re-enter
> your password.")
> return false;
> }
> else return true;
> }
> // End -->
> </script>
>
>
>
> "Qrystems" <(E-Mail Removed)> wrote in message
> news:3D58F756-6C89-469C-A059-(E-Mail Removed)...
> >I was trying to get two inputs like pwd and compare just for confirmation
> > while working in form environment. Can somebody tell me what I need to do?
> > I
> > intend to save the result in MS access dbs
> > Thanks
> > --
> > QRS

>
>
>

 
Reply With Quote
 
Andrew Murray
Guest
Posts: n/a
 
      11th Jul 2005
Yes:
basically the script checks pw1 is the same as pw2 (that's what you wanted
right - a 'enter a password' and "enter password again to verify')....it can
be whatever you like - you can have it check that the person enter's their
email address twice the same if you wanted to.

pw1 and pw2 are just what the author of the script called the fieldnames.

Modify them to whatever you like, or leave them alone, and make sure that
the fields in your form are called "pw1" and "pw2" (the ones that asked for
a password, or email or whatever you want the user to enter twice.).


"Qrystems" <(E-Mail Removed)> wrote in message
news:A6FBF5EA-0115-4B6C-9D1F-(E-Mail Removed)...
> Thanks Mr. Murray
> But what is pw1 and pw2. are they referring to the field names on the
> form?
>
> --
> QRS
>
>
> "Andrew Murray" wrote:
>
>> The form validation in Frontpage doesn't seem to allow what you want to
>> do -
>> I had the same problem, and found this script below on this site:
>> http://javascript.internet.com
>>
>> In the <form> tag, add this bit of javascript exactly as written below:
>>
>> onSubmit="return checkPw(this)"
>>
>>
>> So when user clicks the submit button the script checks the two password
>> fields are the same, else returns an error, and asks for input again.
>> Insert this script below into the <body> section immediately below the
>> body
>> tag, copy and paste into notepad first; then copy into the code view of
>> your
>> web site.
>>
>> <SCRIPT LANGUAGE="JavaScript">
>> <!-- Original: Carey Walker ((E-Mail Removed)) -->
>>
>> <!-- This script and many more are available free online at -->
>> <!-- The JavaScript Source!! http://javascript.internet.com -->
>>
>> <!-- Begin
>> function checkPw(form) {
>> pw1 = form.pw1.value;
>> pw2 = form.pw2.value;
>>
>> if (pw1 != pw2) {
>> alert ("\nYou did not enter the same new password twice. Please re-enter
>> your password.")
>> return false;
>> }
>> else return true;
>> }
>> // End -->
>> </script>
>>
>>
>>
>> "Qrystems" <(E-Mail Removed)> wrote in message
>> news:3D58F756-6C89-469C-A059-(E-Mail Removed)...
>> >I was trying to get two inputs like pwd and compare just for
>> >confirmation
>> > while working in form environment. Can somebody tell me what I need to
>> > do?
>> > I
>> > intend to save the result in MS access dbs
>> > Thanks
>> > --
>> > QRS

>>
>>
>>



 
Reply With Quote
 
Andrew Murray
Guest
Posts: n/a
 
      11th Jul 2005
by the way, this script just checks that the data in the fields are entered
twice; it doesn't interfere with whatever means you use to write the data to
the database, because it validates those fields and makes sure they're
correct *before* submitting the data, and won't submit it until the fields
contain the same data.

"Andrew Murray" <(E-Mail Removed)> wrote in message
news:42d27781$0$5939$(E-Mail Removed)...
> Yes:
> basically the script checks pw1 is the same as pw2 (that's what you wanted
> right - a 'enter a password' and "enter password again to verify')....it
> can be whatever you like - you can have it check that the person enter's
> their email address twice the same if you wanted to.
>
> pw1 and pw2 are just what the author of the script called the fieldnames.
>
> Modify them to whatever you like, or leave them alone, and make sure that
> the fields in your form are called "pw1" and "pw2" (the ones that asked
> for a password, or email or whatever you want the user to enter twice.).
>
>
> "Qrystems" <(E-Mail Removed)> wrote in message
> news:A6FBF5EA-0115-4B6C-9D1F-(E-Mail Removed)...
>> Thanks Mr. Murray
>> But what is pw1 and pw2. are they referring to the field names on the
>> form?
>>
>> --
>> QRS
>>
>>
>> "Andrew Murray" wrote:
>>
>>> The form validation in Frontpage doesn't seem to allow what you want to
>>> do -
>>> I had the same problem, and found this script below on this site:
>>> http://javascript.internet.com
>>>
>>> In the <form> tag, add this bit of javascript exactly as written below:
>>>
>>> onSubmit="return checkPw(this)"
>>>
>>>
>>> So when user clicks the submit button the script checks the two password
>>> fields are the same, else returns an error, and asks for input again.
>>> Insert this script below into the <body> section immediately below the
>>> body
>>> tag, copy and paste into notepad first; then copy into the code view of
>>> your
>>> web site.
>>>
>>> <SCRIPT LANGUAGE="JavaScript">
>>> <!-- Original: Carey Walker ((E-Mail Removed)) -->
>>>
>>> <!-- This script and many more are available free online at -->
>>> <!-- The JavaScript Source!! http://javascript.internet.com -->
>>>
>>> <!-- Begin
>>> function checkPw(form) {
>>> pw1 = form.pw1.value;
>>> pw2 = form.pw2.value;
>>>
>>> if (pw1 != pw2) {
>>> alert ("\nYou did not enter the same new password twice. Please re-enter
>>> your password.")
>>> return false;
>>> }
>>> else return true;
>>> }
>>> // End -->
>>> </script>
>>>
>>>
>>>
>>> "Qrystems" <(E-Mail Removed)> wrote in message
>>> news:3D58F756-6C89-469C-A059-(E-Mail Removed)...
>>> >I was trying to get two inputs like pwd and compare just for
>>> >confirmation
>>> > while working in form environment. Can somebody tell me what I need to
>>> > do?
>>> > I
>>> > intend to save the result in MS access dbs
>>> > Thanks
>>> > --
>>> > QRS
>>>
>>>
>>>

>
>



 
Reply With Quote
 
=?Utf-8?B?UXJ5c3RlbXM=?=
Guest
Posts: n/a
 
      11th Jul 2005
Thanks Mr. Andrew Murray. I will try as suggested. I 'll let you know the
outcome
--
QRS


"Andrew Murray" wrote:

> by the way, this script just checks that the data in the fields are entered
> twice; it doesn't interfere with whatever means you use to write the data to
> the database, because it validates those fields and makes sure they're
> correct *before* submitting the data, and won't submit it until the fields
> contain the same data.
>
> "Andrew Murray" <(E-Mail Removed)> wrote in message
> news:42d27781$0$5939$(E-Mail Removed)...
> > Yes:
> > basically the script checks pw1 is the same as pw2 (that's what you wanted
> > right - a 'enter a password' and "enter password again to verify')....it
> > can be whatever you like - you can have it check that the person enter's
> > their email address twice the same if you wanted to.
> >
> > pw1 and pw2 are just what the author of the script called the fieldnames.
> >
> > Modify them to whatever you like, or leave them alone, and make sure that
> > the fields in your form are called "pw1" and "pw2" (the ones that asked
> > for a password, or email or whatever you want the user to enter twice.).
> >
> >
> > "Qrystems" <(E-Mail Removed)> wrote in message
> > news:A6FBF5EA-0115-4B6C-9D1F-(E-Mail Removed)...
> >> Thanks Mr. Murray
> >> But what is pw1 and pw2. are they referring to the field names on the
> >> form?
> >>
> >> --
> >> QRS
> >>
> >>
> >> "Andrew Murray" wrote:
> >>
> >>> The form validation in Frontpage doesn't seem to allow what you want to
> >>> do -
> >>> I had the same problem, and found this script below on this site:
> >>> http://javascript.internet.com
> >>>
> >>> In the <form> tag, add this bit of javascript exactly as written below:
> >>>
> >>> onSubmit="return checkPw(this)"
> >>>
> >>>
> >>> So when user clicks the submit button the script checks the two password
> >>> fields are the same, else returns an error, and asks for input again.
> >>> Insert this script below into the <body> section immediately below the
> >>> body
> >>> tag, copy and paste into notepad first; then copy into the code view of
> >>> your
> >>> web site.
> >>>
> >>> <SCRIPT LANGUAGE="JavaScript">
> >>> <!-- Original: Carey Walker ((E-Mail Removed)) -->
> >>>
> >>> <!-- This script and many more are available free online at -->
> >>> <!-- The JavaScript Source!! http://javascript.internet.com -->
> >>>
> >>> <!-- Begin
> >>> function checkPw(form) {
> >>> pw1 = form.pw1.value;
> >>> pw2 = form.pw2.value;
> >>>
> >>> if (pw1 != pw2) {
> >>> alert ("\nYou did not enter the same new password twice. Please re-enter
> >>> your password.")
> >>> return false;
> >>> }
> >>> else return true;
> >>> }
> >>> // End -->
> >>> </script>
> >>>
> >>>
> >>>
> >>> "Qrystems" <(E-Mail Removed)> wrote in message
> >>> news:3D58F756-6C89-469C-A059-(E-Mail Removed)...
> >>> >I was trying to get two inputs like pwd and compare just for
> >>> >confirmation
> >>> > while working in form environment. Can somebody tell me what I need to
> >>> > do?
> >>> > I
> >>> > intend to save the result in MS access dbs
> >>> > Thanks
> >>> > --
> >>> > QRS
> >>>
> >>>
> >>>

> >
> >

>
>
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Fileds Johnnyboy5 Microsoft Word New Users 0 28th Aug 2010 10:19 AM
add new fileds =?Utf-8?B?U291cmlz?= Microsoft Access Forms 1 8th Jul 2005 08:00 PM
Re: Set Yes/No Fileds Steve Schapel Microsoft Access Macros 0 10th Sep 2004 09:10 AM
Confirmation Page stops working - where is "server's applicaitonlog" usually stored and any idea why confirmation page died? A.Ron Carmichael Microsoft Frontpage 1 2nd Sep 2003 10:37 AM
Confirmation Fields not appearing on confirmation form Rick Budde Microsoft Frontpage 1 13th Jul 2003 02:49 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 02:41 PM.