I need to add the image so when i click on the image it will submit the amount.
ID: 3551396 • Letter: I
Question
I need to add the image so when i click on the image it will submit the amount. Also is this the way to call two funtions with the onclick event?
action="http://localhost:8090/" method="post" name="exercise_form">
Quantity<INPUT size="10" name="item"/><BR/>
<img alt="" src="web-content/images/homepage/atc.png"
style="width: 118px; height: 31px; position: absolute; top: 275px; left: 435px;" />
<input name="add_to_cart" type="button" value="add";"processCookies()" /><BR/>
Here is the image and the path.
<img alt="" src="web-content/images/homepage/atc.png"
Explanation / Answer
Answer:
To submit the amount on clicking on image u have to the following manner.
<script>
function f1()
{
setCookies(key,book,price);
processCookies();
//alert("1");
}
</script>
<style>
.abc
{
background-image: url('web-content/images/homepage/atc.png');
width: 118px; height: 31px; position: absolute; top: 275px; left: 435px
}
</style>
<form action="">
<input name="add_to_cart" type="button" value="add">
<input type="submit" class="abc" value="">
</form
and it is not possible to call two funtions with the onclick event, to make that possble u have to make a new function and put the two function you want to call with onclick event in body of new function and call this new function with onclick event..
the way to do that is given above.
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.