Side navigation
#794 closed bug (fixed)
Opened January 12, 2007 09:21PM UTC
Closed January 13, 2007 10:32PM UTC
Last modified June 19, 2007 09:24AM UTC
Default action gets called with FF2 even after jQuery(f).submit(function(e) { ... }) is defined.
Reported by: | tuupola@appelsiini.n | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | 1.1 |
Component: | event | Version: | 1.1 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
Default form action gets called (browser submits the form) with FF2 even after jQuery(f).submit(function(e) { ... }) is defined with code below. This used to work with 1.0.4. I have tested with OSX FF 2.0.0.1 and Safari 2.0.4. Code fails only with FF.
Live examples at:
http://www.appelsiini.net/~tuupola/jquery/bugs/onblur-1.1b.html
http://www.appelsiini.net/~tuupola/jquery/bugs/onblur-1.0.4.html
$(document).ready(function() { var f = $('form'); var i = document.createElement('textarea'); i.name = 'foo'; var b = document.createElement('input'); b.type = 'submit'; b.value = 'OK'; f.append(i); f.append(b); jQuery(i).blur(function(e) { jQuery(f).submit(); }); jQuery(f).submit(function(e) { e.preventDefault(); console.log('submit'); }); });
Attachments (0)
Change History (1)
Changed January 13, 2007 10:32PM UTC by comment:1
milestone: | → 1.1 |
---|---|
resolution: | → fixed |
status: | new → closed |
Fixed in SVN rev 1049.