I found one on codetoad.com, but for some reason it doesnt send my form results through when I add it, any ideas why?
I have posted my code that works without calendar and the code with the calendar that doesnt send the form results through
My working code (no calendar) is like this:
<html xmlns:fo="
<head>
<META http-equiv="Content-Type" content="text/html; charset=UTF-16">
<title>Severn Trent Quote Form</title>
<style type="text/css">
<!--.primary {
font-family: Arial, Helvetica, sans-serif;
font-size: 12px;
background-color: #FFFFFF;
}
.style1 {
font-size: 14px;
font-weight: bold;
color: #3366CC;
background-color: #FFFFFF;
}
.required {
color: #FF0000;
font-weight: bold;
font-family: Arial, Helvetica, sans-serif;
font-size: 11px;
}
.input_glow {
font-family: Arial, "Courier New", Courier, mono;
font-size: 12px;
background-color: #FFFF99;
}
.input_standard {
font-family: Arial, "Courier New", Courier, mono;
font-size: 12px;
background-color: #FFFFFF;
}
.style2 {
font-size: 12px;
color: #000000;
font-weight: bold;
font-family: Arial, Helvetica, sans-serif;
}
.style4 {font-size: 9px}
-->
</style><script language="JavaScript" type="text/JavaScript">
<!--
document.MM_returnValue=true;document.MyErrors='';
function MM_findObj(n, d) {var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms
[n];for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers.document);if(!x && d.getElementById) x=d.getElementById
; return x;}
function MM_validateForm() {var i,p,q,nm,test,num,min,max,errors='',args=MM_validateForm.arguments;for (i=0; i<(args.length-2); i+=3) { test=args[i+2]; val=MM_findObj(args);if (val) { nm=val.name;pnm='pretty_'+nm;po=MM_findObj(pnm);if(po){ponm=po.value;}else{ponm=nm;}if ((val=val.value)!="") {if (test.indexOf('isEmail')!=-1) { p=val.indexOf('@');if (p<1 || p==(val.length-1)) {if (errors.indexOf('must contain an e-mail')==-1){errors+='- '+ponm+' must contain an e-mail address.\n';}}} else if (test!='R') { num = parseFloat(val);if (isNaN(val)) errors+='- '+ponm+' must contain a number.\n';if (test.indexOf('inRange') != -1) { p=test.indexOf(':');min=test.substring(8,p); max=test.substring(p+1);if (num<min || max<num) errors+='- '+ponm+' must contain a number between '+min+' and '+max+'.\n';} } } else if (test.charAt(0) == 'R') errors += '- '+ponm+' is required.\n'; }} if (errors){document.MyErrors +=errors;document.MM_returnValue=false;}}
function ShowErrors(){if (document.MyErrors!=''){alert('The following error(s) occurred:\n'+document.MyErrors);}}
-->
</script></head>
<body class="primary">
<table width="100%">
<form method="POST" name="frmGMGenerated" target="_self" id="frmGMGenerated" action="
<tr>
<td width="99%">
<img src=" .png" width="276" height="66"></p>
<p class="style4">Please provide us with as much
information as you can in order for us to generate a quote. Please complete the form below.
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td colspan="3" class="style1">Primary Information</td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Agents Name </td>
<td width="915"><!----><select tabindex="24" name="URESDATA" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'"><option selected value="">Select Agent Name</option>
<option value="Test 1">Test 1</option>
<option value="Test 2">Test 2</option>
<option value="Test 3">Test 3</option>
<option value="Test 4">Test 4</option>
<option value="Test 5">Test 5</option>
<option value="Test 6">Test 6</option>
</td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Full Name</td>
<td width="915"><input tabindex="2" type="text" id="CONTACT" name="CONTACT" size="40" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="40"></td>
<input type="hidden" value="CONTACT" name="DuplicateChecking1" id="DuplicateChecking1">
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">E-mail</td>
<td width="915"><input tabindex="8" type="text" id="EMAIL" name="EMAIL" size="40" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="50"></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Phone Number</td>
<td nowrap="true" width="100">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td nowrap="true" width="260"><input tabindex="9" type="text" id="PHONE1" name="PHONE1" size="30" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="25"></td>
</tr>
</table>
</td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Alt. Phone Number</td>
<td nowrap="true" width="100">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td nowrap="true" width="260"><input tabindex="9" type="text" id="PHONE2" name="PHONE2" size="30" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="25"></td>
</tr>
</table>
</td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Address1</td>
<td width="915"><input tabindex="18" type="text" id="ADDRESS1" name="ADDRESS1" size="60" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="40"></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Address2</td>
<td width="915"><input tabindex="19" type="text" id="ADDRESS2" name="ADDRESS2" size="60" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="40"></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Address3</td>
<td width="915"><input tabindex="20" type="text" id="ADDRESS3" name="ADDRESS3" size="60" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="40"></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">City</td>
<td nowrap><input tabindex="21" type="text" id="CITY" name="CITY" size="30" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="30"></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">County</td>
<td nowrap><input tabindex="21" type="text" id="STATE" name="STATE" size="30" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="30"></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Post Code</td>
<td nowrap><input tabindex="23" type="text" id="ZIP" name="ZIP" size="15" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="10"></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Best Date To Call </td>
<td nowrap><input tabindex="21" type="text" id="UENRESDTC" name="UENRESDTC" size="30" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="30">
<span class="style4">(dd/mm/yyyy) </span></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Best Time To Call </td>
<td width="915"><!----><select tabindex="24" name="UENRESTTC" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'"><option selected value="">Choose Time</option>
<option value="09:00-10:00">09:00-10:00</option>
<option value="10:00-11:00">10:00-11:00</option>
<option value="11:00-12:00">11:00-12:00</option>
<option value="12:00-13:00">12:00-13:00</option>
<option value="13:00-14:00">13:00-14:00</option>
<option value="14:00-15:00">14:00-15:00</option>
<option value="15:00-16:00">15:00-16:00</option>
<option value="16:00-17:00">16:00-17:00</option>
<option value="17:00-18:00">17:00-18:00</option>
<option value="18:00-19:00">18:00-19:00</option>
<option value="19:00-20:00">19:00-20:00</option>
</TR>
</td>
<BR>
<BR>
<tr>
<td colspan="3" class="style1">Secondary Information</td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td class="style2" nowrap="true" width="140">Partner Code</td>
<td width="915"><input name="KEY3" type="text" id="KEY3" tabIndex="26" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" value="cat208" size="30" maxlength="20">
<span class="style4">Please leave this value </span></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td class="style2" nowrap="true" width="140">Source Code</td>
<td width="915"><input type="text" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="20" id="SOURCE" name="SOURCE" value="ST_Referal" tabIndex="27" size="30">
<span class="style4"> Please leave this value </span></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<label>
<span class="style2"> Please Enter Any Additional Comments/Notes</span>
<textarea name="NOTES" id="NOTES"></textarea>
</label>
</TR>
</TABLE><br><input type="hidden" name="SMTP" id="SMTP" value="6D3C1E5069321E4C51210634704013416A39"><input type="hidden" name="SendToEmail" id="SendToEmail" value="90291180A438096D973109789321117E7F3F1E8191300478902F0672A229198C9D29103D8F2C1786A3360471963120929E3B1982A1400A7662340164A8391F4DA32E0A75"><input type="hidden" name="DupLogic" id="DupLogic" value=""><input type="hidden" name="OnDupAttachTrack" id="OnDupAttachTrack" value=""><input type="hidden" name="OnNewAttachTrack" id="OnNewAttachTrack" value="7C391A8FA83505799D2E0976A54014865636035A99341783A23F1D8CA0331B80"><input type="hidden" name="OnDUPSendGMEmail" id="OnDUPSendGMEmail" value="7532054D7F2D0C558936"><input type="hidden" name="OnNewSendGMEmail" id="OnNewSendGMEmail" value="7C3918608D3B0A53812E"><input type="hidden" name="Word" id="Word" value=""><input type="hidden" name="DuplicateCount" id="DuplicateCount" value="1"><input type="hidden" name="OutPutAs" id="OutPutAs" value="INI"></td>
</tr>
<tr>
<td align="right" nowrap="true" width="560"><input tabindex="99" type="Reset" id="Reset" name="Reset" value="Reset form"><font color="FFFFFF">x</font><input tabindex="100" type="submit" id="GMsubmit" name="GMsubmit" value="Submit form"></td>
<input name="redirect" type="hidden" value="
<td>
</td>
</tr>
</form>
</table>
</body>
</html>
Calendar code:
<html xmlns:fo="
<head>
<script language="JavaScript" src="
//Script by Denis Gritcyuk: tspicker@yahoo.com
//Submitted to JavaScript Kit (//Visit for this script
</script>
<META http-equiv="Content-Type" content="text/html; charset=UTF-16">
<title>Severn Trent Quote Form</title>
<style type="text/css">
<!--.primary {
font-family: Arial, Helvetica, sans-serif;
font-size: 12px;
background-color: #FFFFFF;
}
.style1 {
font-size: 14px;
font-weight: bold;
color: #3366CC;
background-color: #FFFFFF;
}
.required {
color: #FF0000;
font-weight: bold;
font-family: Arial, Helvetica, sans-serif;
font-size: 11px;
}
.input_glow {
font-family: Arial, "Courier New", Courier, mono;
font-size: 12px;
background-color: #FFFF99;
}
.input_standard {
font-family: Arial, "Courier New", Courier, mono;
font-size: 12px;
background-color: #FFFFFF;
}
.style2 {
font-size: 12px;
color: #000000;
font-weight: bold;
font-family: Arial, Helvetica, sans-serif;
}
.style4 {font-size: 9px}
-->
</style><script language="JavaScript" type="text/JavaScript">
<!--
document.MM_returnValue=true;document.MyErrors='';
function MM_findObj(n, d) {var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[n];for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers.document);if(!x && d.getElementById) x=d.getElementById
; return x;}
function MM_validateForm() {var i,p,q,nm,test,num,min,max,errors='',args=MM_validateForm.arguments;for (i=0; i<(args.length-2); i+=3) { test=args[i+2]; val=MM_findObj(args);if (val) { nm=val.name;pnm='pretty_'+nm;po=MM_findObj(pnm);if(po){ponm=po.value;}else{ponm=nm;}if ((val=val.value)!="") {if (test.indexOf('isEmail')!=-1) { p=val.indexOf('@');if (p<1 || p==(val.length-1)) {if (errors.indexOf('must contain an e-mail')==-1){errors+='- '+ponm+' must contain an e-mail address.\n';}}} else if (test!='R') { num = parseFloat(val);if (isNaN(val)) errors+='- '+ponm+' must contain a number.\n';if (test.indexOf('inRange') != -1) { p=test.indexOf(':');min=test.substring(8,p); max=test.substring(p+1);if (num<min || max<num) errors+='- '+ponm+' must contain a number between '+min+' and '+max+'.\n';} } } else if (test.charAt(0) == 'R') errors += '- '+ponm+' is required.\n'; }} if (errors){document.MyErrors +=errors;document.MM_returnValue=false;}}
function ShowErrors(){if (document.MyErrors!=''){alert('The following error(s) occurred:\n'+document.MyErrors);}}
-->
</script></head>
<body class="primary">
<table width="100%">
<form method="POST" name="frmGMGenerated" target="_self" id="frmGMGenerated" action="
<tr>
<td width="99%">
<img src=" .png" width="276" height="66"></p>
<p class="style4">Please provide us with as much
information as you can in order for us to generate a quote. Please complete the form below.
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td colspan="3" class="style1">Primary Information</td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Agents Name </td>
<td width="915"><!----><select tabindex="24" name="URESDATA" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'"><option selected value="">Select Agent Name</option>
<option value="Test 1">Test 1</option>
<option value="Test 2">Test 2</option>
<option value="Test 3">Test 3</option>
<option value="Test 4">Test 4</option>
<option value="Test 5">Test 5</option>
<option value="Test 6">Test 6</option>
</td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Full Name</td>
<td width="915"><input tabindex="2" type="text" id="CONTACT" name="CONTACT" size="40" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="40"></td>
<input type="hidden" value="CONTACT" name="DuplicateChecking1" id="DuplicateChecking1">
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">E-mail</td>
<td width="915"><input tabindex="8" type="text" id="EMAIL" name="EMAIL" size="40" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="50"></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Phone Number</td>
<td nowrap="true" width="100">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td nowrap="true" width="260"><input tabindex="9" type="text" id="PHONE1" name="PHONE1" size="30" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="25"></td>
</tr>
</table>
</td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Alt. Phone Number</td>
<td nowrap="true" width="100">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td nowrap="true" width="260"><input tabindex="9" type="text" id="PHONE2" name="PHONE2" size="30" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="25"></td>
</tr>
</table>
</td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Address1</td>
<td width="915"><input tabindex="18" type="text" id="ADDRESS1" name="ADDRESS1" size="60" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="40"></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Address2</td>
<td width="915"><input tabindex="19" type="text" id="ADDRESS2" name="ADDRESS2" size="60" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="40"></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Address3</td>
<td width="915"><input tabindex="20" type="text" id="ADDRESS3" name="ADDRESS3" size="60" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="40"></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">City</td>
<td nowrap><input tabindex="21" type="text" id="CITY" name="CITY" size="30" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="30"></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">County</td>
<td nowrap><input tabindex="21" type="text" id="STATE" name="STATE" size="30" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="30"></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Post Code</td>
<td nowrap><input tabindex="23" type="text" id="ZIP" name="ZIP" size="15" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="10"></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Best Date To Call </td>
<td nowrap><input tabindex="21" type="text" id="UENRESDTC" name="UENRESDTC" value="" size="30" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="30">
<a href="javascript:show_calendar('document.frmGMGenerated.UENRESDTC', document.frmGMGenerated.UENRESDTC.value);"><img src=" width="16" height="16" border="0" alt="Click Here to Pick up the timestamp"></a>
</td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td nowrap="true" width="140" class="style2">Best Time To Call </td>
<td width="915"><!----><select tabindex="24" name="UENRESTTC" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'"><option selected value="">Choose Time</option>
<option value="09:00-10:00">09:00-10:00</option>
<option value="10:00-11:00">10:00-11:00</option>
<option value="11:00-12:00">11:00-12:00</option>
<option value="12:00-13:00">12:00-13:00</option>
<option value="13:00-14:00">13:00-14:00</option>
<option value="14:00-15:00">14:00-15:00</option>
<option value="15:00-16:00">15:00-16:00</option>
<option value="16:00-17:00">16:00-17:00</option>
<option value="17:00-18:00">17:00-18:00</option>
<option value="18:00-19:00">18:00-19:00</option>
<option value="19:00-20:00">19:00-20:00</option>
</TR>
</td>
<BR>
<BR>
<tr>
<td colspan="3" class="style1">Secondary Information</td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td class="style2" nowrap="true" width="140">Partner Code</td>
<td width="915"><input name="KEY3" type="text" id="KEY3" tabIndex="26" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" value="cat208" size="30" maxlength="20">
<span class="style4">Please leave this value </span></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<td class="style2" nowrap="true" width="140">Source Code</td>
<td width="915"><input type="text" class="input_standard" onFocus="javascript:className='input_glow'" onBlur="javascript:className='input_standard'" maxlength="20" id="SOURCE" name="SOURCE" value="ST_Referal" tabIndex="27" size="30">
<span class="style4"> Please leave this value </span></td>
</tr>
<tr>
<td nowrap="true" width="10">
</td>
<label>
<span class="style2"> Please Enter Any Additional Comments/Notes</span>
<textarea name="NOTES" id="NOTES"></textarea>
</label>
</TR>
</TABLE><br><input type="hidden" name="SMTP" id="SMTP" value="6D3C1E5069321E4C51210634704013416A39"><input type="hidden" name="SendToEmail" id="SendToEmail" value="90291180A438096D973109789321117E7F3F1E8191300478902F0672A229198C9D29103D8F2C1786A3360471963120929E3B1982A1400A7662340164A8391F4DA32E0A75"><input type="hidden" name="DupLogic" id="DupLogic" value=""><input type="hidden" name="OnDupAttachTrack" id="OnDupAttachTrack" value=""><input type="hidden" name="OnNewAttachTrack" id="OnNewAttachTrack" value="7C391A8FA83505799D2E0976A54014865636035A99341783A23F1D8CA0331B80"><input type="hidden" name="OnDUPSendGMEmail" id="OnDUPSendGMEmail" value="7532054D7F2D0C558936"><input type="hidden" name="OnNewSendGMEmail" id="OnNewSendGMEmail" value="7C3918608D3B0A53812E"><input type="hidden" name="Word" id="Word" value=""><input type="hidden" name="DuplicateCount" id="DuplicateCount" value="1"><input type="hidden" name="OutPutAs" id="OutPutAs" value="INI"></td>
</tr>
<tr>
<td align="right" nowrap="true" width="560"><input tabindex="99" type="Reset" id="Reset" name="Reset" value="Reset form"><font color="FFFFFF">x</font><input tabindex="100" type="submit" id="GMsubmit" name="GMsubmit" value="Submit form"></td>
<input name="redirect" type="hidden" value="
<td>
</td>
</tr>
</form>
</table>
</body>
</html>