Firefox and (no-attached-Form).submit()

Firefox and (no-attached-Form).submit()

Hi!

I found a bug I do not know if it's a mismatch of Firefox or jQuery.
Well, is as follows: When you create a <form> via jQuery and uses the method .submit(), nothing happens.
To do work, you must attach to the document before.
In other browsers everything occurs as expected.

One way to work, would by to use the method. Submit () in Firefox and attach (temporarily) the form and run the document, if not attached.


  1.     var form = $('<form action="" method="post">');
  2.     var hidden = $('<input type="hidden" name="server-post"/>');
  3.     hidden.val($(this).attr('href-post')).appendTo(form);
  4.     form.appendTo($('body'))
  5.       .submit();
The blue part shows basically what the jQuery would do.

Bye.
Note: I report the information to Mozilla as well, maybe they can do their part.