In my project i create using Ajax DOM a POST form. I have to add an onsubmit method, i try:
var impform = document.createElement("FORM");
impform.method = "post";
impform.onsubmit = "/import_templ";
but wher i load my webpage form are created ok and method was POST but there isn't the onsubmit method.
How can i add my onsubmit method to the form?
Thanks in advance