dennic
02-18-2003, 07:38 PM
how do i send a form to an email address without using server side scripting?? can i use either html or javascript. here is the scripting i have:
<SCRIPT LANGUAGE="javascript">
<!--
function check() {
c=document.quotes;
if(c.name.value==""){
alert("You must enter your name!");
c.name.focus();
return false;
} else if(c.email.value==""){
alert("You must enter your email address!");
c.email.focus();
return false;
} else if(c.phone.value==""){
alert("You must fill in your phone number!");
c.phone.focus();
return false;
} else {
alert("Your information has been submitted!");
return true;
}
}
//-->
</SCRIPT>
</head>
<body>
<br>
<br>
<!--Start of form-->
<form name="quotes" >
<center>
<!--Table 1-->
<table width="75%">
<tr>
<td>Contact Name:
<td><input type="text" id="name" size="23" > *
</tr>
<tr>
<td>Company Name:
<td><input type="text" id="company" size="23" >
</tr>
<tr>
<td>Email Address:
<td><input type="text" id="email" size="23" /> *
</tr>
<tr>
<td>Phone Number:
<td><input type="text" id="phone" size="23" /> *
</tr>
<tr>
<td>Fax Number:
<td><input type="text" id="fax" size="23" />
</tr>
<tr>
<td>Colours Available:
<td><select id="colour">
<option>Capricorn Buff</option>
<option>Federation Buff</option>
<option>Heritage Pink</option>
<option>Brown/Yellow Banded</option>
<option>Capricorn Sunset</option>
</select>
</tr>
<tr>
<td>Material Type:
<td><select id="materials">
<option>Blocks</option>
<option>Slab</option>
<option>Bricks</option>
</tr>
</table>
<!--End of table 1-->
</center>
<br>
<br>
<center>
<input type="submit" value="Submit" name="quotes" onClick="return check()">
</center>
</form>
<SCRIPT LANGUAGE="javascript">
<!--
function check() {
c=document.quotes;
if(c.name.value==""){
alert("You must enter your name!");
c.name.focus();
return false;
} else if(c.email.value==""){
alert("You must enter your email address!");
c.email.focus();
return false;
} else if(c.phone.value==""){
alert("You must fill in your phone number!");
c.phone.focus();
return false;
} else {
alert("Your information has been submitted!");
return true;
}
}
//-->
</SCRIPT>
</head>
<body>
<br>
<br>
<!--Start of form-->
<form name="quotes" >
<center>
<!--Table 1-->
<table width="75%">
<tr>
<td>Contact Name:
<td><input type="text" id="name" size="23" > *
</tr>
<tr>
<td>Company Name:
<td><input type="text" id="company" size="23" >
</tr>
<tr>
<td>Email Address:
<td><input type="text" id="email" size="23" /> *
</tr>
<tr>
<td>Phone Number:
<td><input type="text" id="phone" size="23" /> *
</tr>
<tr>
<td>Fax Number:
<td><input type="text" id="fax" size="23" />
</tr>
<tr>
<td>Colours Available:
<td><select id="colour">
<option>Capricorn Buff</option>
<option>Federation Buff</option>
<option>Heritage Pink</option>
<option>Brown/Yellow Banded</option>
<option>Capricorn Sunset</option>
</select>
</tr>
<tr>
<td>Material Type:
<td><select id="materials">
<option>Blocks</option>
<option>Slab</option>
<option>Bricks</option>
</tr>
</table>
<!--End of table 1-->
</center>
<br>
<br>
<center>
<input type="submit" value="Submit" name="quotes" onClick="return check()">
</center>
</form>