function checkform()
{
contactperson=document.f1.contactperson.value;
yourmobile=document.f1.yourmobile.value;
youremail=document.f1.youremail.value;
yourcity=document.f1.yourcity.value;
add_details=document.f1.add_details.value;

if (contactperson=="")
{
alert("Contact Person cannot be empty");
document.f1.contactperson.focus();
return;
}
if (yourmobile=="")
{
alert("Mobile Number cannot be empty");
document.f1.yourmobile.focus();
return;
}
if (youremail=="")
{
alert("Please type your email addresss");
document.f1.youremail.focus();
return;
}
if (yourcity=="")
{
alert("Enter your city");
document.f1.yourcity.focus();
return;
}
if (add_details=="")
{
alert("Enter your query");
document.f1.add_details.focus();
return;
}
document.f1.submit();
}
document.write('<form action="enquiry-venus.php" method=post name=f1><table width="260" height="300" border="0" cellspacing="0" cellpadding="0" align="center" background="images/enquiry_bg.jpg" valign="top" style="background-repeat:no-repeat;">');
document.write('<tr><td align="center" valign="top"><img src="images/blank.gif" width="1" height="30"/></td></tr>');
document.write('<tr><td width="100" height="28"><div class="sendenquiry">Name:</div></td><td width="85"><input size="14" name="contactperson" value="" class="txtTextbox" type="text" /></td></tr>');
document.write('<tr><td><img src="images/blank.gif" width="1" height="5" alt="" border="0"></td></tr>');
document.write('<tr><td width="95"><div class="sendenquiry">Mobile:</div></td><td width="85"><input size="14" name="yourmobile" value="" class="txtTextbox" type="text" /></td></tr>');
document.write('<tr><td><img src="images/blank.gif" width="1" height="5" alt="" border="0"></td></tr>');
document.write('<tr><td width="95"><div class="sendenquiry">Emailid:</div></td><td width="85"><input name="youremail" value="" size="14" class="txtTextbox" type="text" /></td></tr>');
document.write('<tr><td><img src="images/blank.gif" width="1" height="5" alt="" border="0"></td></tr>');
document.write('<tr><td width="95"><div class="sendenquiry">City:</div></td><td width="85"><input name="yourcity" value="" size="14" class="txtTextbox" type="text" /></td></tr>');
document.write('<tr><td><img src="images/blank.gif" width="1" height="5" alt="" border="0"></td></tr>');
document.write('<tr><td width="95" valign="top"><div class="sendenquiry">Enquiry Details:</div></td><td width="85"><textarea cols="11" rows="2" name="add_details" class="txtTextarea" value=""></textarea></td></tr>');
document.write('<tr><td><img src="images/blank.gif" width="1" height="5" alt="" border="0"></td></tr>');
document.write('<tr><td align="center" colspan="2"><a><img src="images/send.jpg" width="56" height="23" border="0" onClick="checkform()" /></a></td></tr>');
document.write('<tr><td><img src="images/blank.gif" width="1" height="30" alt="" border="0"></td></tr></table></form>');
