I am trying to set some hidden form field values using the onclick event. Ok, after I did something like this:
document.getElementById('hidden_field').value = 123;
I can output the value using the firebug console by typing this:
alert(document.getElementById('hidden_field').value);
So, the values are definitely set. But now, when I submit the form, the values of the hidden field are still empty.
Do you have any idea what is going wrong?
source
share