hello there,
this is my code and i dont know why is not working ... hope someone can tell me what is the problem ...
HTML Code:
<script type="text/javascript">
function checkForm() {
name = document.getElementById("name").value;
email = document.getElementById("email").value;
if (name == "") {
hideAllErrors();
document.getElementById("nameError").style.display = "inline";
document.getElementById("name").select();
document.getElementById("name").focus();
return false;
} else if (email == "") {
hideAllErrors();
document.getElementById("emailError").style.display = "inline";
document.getElementById("email").select();
document.getElementById("email").focus();
return false;
}
return true;
}
function hideAllErrors() {
document.getElementById("nameError").style.display = "none"
document.getElementById("emailError").style.display = "none"
}
</script>
<form onsubmit="return checkForm();" method="post" action="contact.php" class="form_contact">
<div class="left">Full Name:</div>
<div class="right"><input type="text" name="name" id="name" size="20" /></div>
<div style="clear: both;"></div>
<div class="left">Email:</div>
<div class="right"><input type="text" name="email" id="email" /></div>
<div style="clear: both;"></div>
<div class="ordernow_p">
<input type="hidden" name="sendmail" id="sendmail" value="sendmail" /><div class="process_order"><a href="javascript:document.submit.submit();"></a></div>
</div>
</form>
when i click on the submit photo is not working ... but if i change the input submit code
HTML Code:
<input class="contact_form3" class="buttons" name="sendmail" id="sendmail" type="submit" value="Send Msg !" />
is working ... can someone help me with this command ...
i think this is the problem ...
HTML Code:
<input type="hidden" name="sendmail" id="sendmail" value="sendmail" /><div class="process_order"><a href="javascript:document.submit.submit();"></a></div>
|