I have a <form id="foo" action="bar.php" method="post"> that has 2 submit buttons, name="save" and name="lock".
I'm running a jquery function:
$("a#submit").click(function() {
$("#foo").submit();
});
How can I tell jQuery to submit the name lock and not the other one?
$("input[name='lock']").click();why cant you use this?$("input[name='lock']")[0].click();namebutton then go to action 1, clicklockbutton then go to action 2?<input type="submit">, one has a name ofsaveand the other haslock. I want to trigger the lock one.