Correct me if I'm wrong, but calling form.onsubmit() works great only IF you've
actually got an onsubmit event specified in the form tag as <form
onsubmit="somefunction()">. But if you add events programmatically, e.g.
addEventListener, this seems to fail.
Correct me if I'm wrong, but calling form.onsubmit() works great only IF you've actually got an onsubmit event specified in the form tag as <form onsubmit="somefunction()">. But if you add events programmatically, e.g. addEventListener, this seems to fail.