Wrox Programmer Forums
|
Pro JSP Advanced JSP coding questions. Beginning questions will be redirected to the Beginning JSP forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Pro JSP section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 11th, 2004, 08:11 AM
Registered User
 
Join Date: Dec 2004
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default Validate form

Hi
I'm quite new at javascript but got a little bit of no how. anyway i've got a form i want validated, What i'm try to do is validate the whole form for correct input and no null fields aswell as validate the 'password' against the 'VPassword' so that users have to enter a password twice which matches, anyway here's the whole page.
please help i'm getting low on hair to pull out.

<%@ LANGUAGE = "VBSCRIPT" %>
<% OPTION EXPLICIT %>


<html>
<head>
    <title>Customer Information Form</title>

<link rel="stylesheet" type="text/css" href="mystyles.css">


</head>
<BODY BACKGROUND="graphics\bg1.gif" Link="yellow" VLINK="silver" ALINK="white">




<CENTER><FORM name='CustFrm' action='custadd.asp?CartID=<%=CartID%>' method='POST'>
<p>Please provide the following information to start an account:</p>

<TABLE border="0" cellpadding="2" cellspacing="2" >
<TR>
    <TD>
   First Name :
    </TD>
    <TD>
   <INPUT type='text' name='FName' size='20' value=''>
    </TD>
</TR>
<TR>
    <TD>
   Last Name :
    </TD>
    <TD>
   <INPUT type='text' name='LName' size='20' value=''>
    </TD>
</TR>
<TR>
    <TD>
   Address :
    </TD>
    <TD>
   <INPUT type='text' name='Address' size='40' value=''>
    </TD>
</TR>
<TR>
    <TD>
   City :
    </TD>
    <TD>
   <INPUT type='text' name='City' size='20' value=''>
    </TD>
</TR>
<TR>
    <TD>
   Post Code :
    </TD>
    <TD>
   <INPUT type='text' name='PostCode' size='10' value=''>
    </TD>
</TR>
<TR>
    <TD>
   Country :
    </TD>
    <TD>
   <INPUT type='text' name='Country' size='15' value=''>
    </TD>
</TR>
<TR>
    <TD>
   Phone :
    </TD>
    <TD>
   <INPUT type='text' name='Phone' size='20' value=''>
    </TD>
</TR>
<TR>
    <TD>
   E-Mail :
    </TD>
    <TD>
   <INPUT type='text' name='EMail' size='40' value=''>
    </TD>
</TR>
<TR>
    <TD>
   Username :
    </TD>
    <TD>
   <INPUT type='text' name='Username' size='20' value=''>
    </TD>
</TR>
<TR>
    <TD>
   Password :
    </TD>
    <TD>
   <INPUT type='password' name='Password' size='20' value=''>
    </TD>
</TR>
<TR>
    <TD>
   Verify Password :
    </TD>
    <TD>
   <INPUT type='password' name='VPassword' size='20' value=''>
    </TD>
</TR>
<TR>
    <TD>

    </TD>
    <TD>
   <INPUT type='reset' name='reset' value='Reset the form'>
    </TD>
</TR>
<TR>
    <TD>

    </TD>
    <TD>
   <INPUT type='submit' name='submit' value='Send info'>
    </TD>
</TR>
</TABLE>
</FORM>

</CENTER>
</body>
</html>





Similar Threads
Thread Thread Starter Forum Replies Last Post
Form doesn't w3c validate, html 4.01 mps2006 HTML Code Clinic 1 November 26th, 2006 03:41 AM
chapter 3 validate form. lucian BOOK: Professional Ajax ISBN: 978-0-471-77778-6 0 October 16th, 2006 05:17 AM
Validate Event tbriers Pro VB 6 1 April 2nd, 2004 08:57 PM
Validate calculated field in sub form MG76 Access 4 March 18th, 2004 04:26 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.