I
Ice Man
Hi all
How Can I submit a form by clicking on an image instead of the submit
button?
Thanks
How Can I submit a form by clicking on an image instead of the submit
button?
Thanks
Elie Grouchko said:Use JavaScript code that will submit the form as a result of the click
event:
<html>
<head>
<script type="text/javascript">
function SubmitForm()
{
document.getElementById("form1").submit();
}
</script>
</head>
<body>
<form id="form1" action="page2.htm" method="post">
<img src="" onclick="SubmitForm()">
</form>
</body>
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.