Thursday, March 15, 2012

submit form using javascript


submit form using javascript   submit form using javascript  submit form using javascript

First name:
Last name:





<script type="text/javascript">
function formSubmit()
{
document.getElementById("formid").submit();
}
</script>


<form id="formid" action="myform.php">
First name: <input type="text" name="fname" /><br />
Last name: <input type="text" name="lname" /><br /><br />

<input type="button" onclick="formSubmit()" value="Submit form" />
</form>

1 comment:

If you Satisfied , Please Leave a comment