It appears you have not yet registered with DEVPPL. To register please click here... (it's fast, easy and free!)

Forum

Log In Sponsors
Board index Programming Java Forum

HELP WITH REQUIRED FIELD

HELP WITH REQUIRED FIELD

Postby ivi on Mon Nov 20, 2006 6:19 pm

Hellow people!

I have this form here:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>
<script language="JavaScript" type="text/javascript">
<!--
function checkform ( form )
{
// see http://www.thesitewizard.com/archive/validation.shtml
// for an explanation of this script and how to use it on your
// own website

// ** START **
if (form.email.value == "") {
alert( "Please enter your email address." );
form.email.focus();
return false ;
}
// ** END **
return true ;
}
//-->
</script>

</head>

<body>

<form action="mailto:yourname@yourdomain.com" method="post" onsubmit="return checkform(this);">
<form id="form1" name="form1" method="post" action="">
<input type="text" name="email" />
<input type="submit" name="Submit" value="Submit" />
</form>
</body>
</html>


It is working good but I need to include 2 more fields to be required as well:

They are:

name1
message2

How Do I include???
ivi
 
Posts: 0
Joined: Mon Nov 20, 2006 6:13 pm

Who is online

Users browsing this forum: No registered users and 2 guests