I have a form with two buttons, each with onclick = this.form.submit(). I have a hidden field in the form, and I would like the value of the field to be different based on which
You could pass the value to which you want to set the hidden input to a function you create:
function handleClick(val){ document.getElementById('HiddenInputID').value = val; return true; }
and then code the buttons using the onclick to pass whichever value you'd like:
onclick