Reputation: 1768
HI guys,
is there any way to find which control is submitting the form through JavaScript??
also if one defined a JavaScript function to be called on the form submit event is there a way to find the control which caused the submission
Thanks a lot
Upvotes: 0
Views: 352
Reputation: 943996
As far as I know, this can only be achieved by adding an event handler to each submit button. For example:
function () {
this.form.submission_trigger = this;
};
Upvotes: 1
Reputation: 38160
On the client side?
With firebug you can.
You would have to overwrite the onsubmit event with : console.trace
So you would have to enter document.getElementById("FORMID").onsubmit=console.trace
Upvotes: 0
Reputation: 19
on the server side if you have this you can see all infromation which user submit on the page include control
Upvotes: 0