Side navigation
#954 closed bug (worksforme)
Opened February 13, 2007 09:03PM UTC
Closed September 15, 2007 01:30PM UTC
Last modified March 14, 2012 08:32PM UTC
IE form serialization bug
Reported by: | admin@ngcoders.com | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | 1.2 |
Component: | core | Version: | 1.1.4 |
Keywords: | IE , serialize | Cc: | |
Blocked by: | Blocking: |
Description
When i try to serialize a form in IE it does not work , firefox and Opera work fine. This leads to forms submitted in IE not having the correct fields.
After a little debugging i made a small fix ( works for me in IE , firefox and Opera ) .
in jquery .js after line 2164 i put the following code
var k = false;
if ( a[0][0] != undefined) k = a[0];
if ( a.constructor == Array || a.jquery || k)
Serialize the form elements
jQuery.each( (k)?k:a, function(){
s.push( encodeURIComponent(this.name) + "=" + encodeURIComponent( this.value ) );
});
replacing the original
if ( a.constructor == Array || a.jquery)
Serialize the form elements
jQuery.each( a, function(){
s.push( encodeURIComponent(this.name) + "=" + encodeURIComponent( this.value ) );
});
Attachments (0)
Change History (2)
Changed May 02, 2007 12:22AM UTC by comment:1
Changed September 15, 2007 01:30PM UTC by comment:2
description: | When i try to serialize a form in IE it does not work , firefox and Opera work fine. This leads to forms submitted in IE not having the correct fields. \ \ After a little debugging i made a small fix ( works for me in IE , firefox and Opera ) .\ \ in jquery .js after line 2164 i put the following code \ \ var k = false;\ \ if ( a[0][0] != undefined) k = a[0]; \ \ if ( a.constructor == Array || a.jquery || k)\ // Serialize the form elements\ jQuery.each( (k)?k:a, function(){\ s.push( encodeURIComponent(this.name) + "=" + encodeURIComponent( this.value ) );\ });\ \ replacing the original \ \ if ( a.constructor == Array || a.jquery)\ // Serialize the form elements\ jQuery.each( a, function(){\ s.push( encodeURIComponent(this.name) + "=" + encodeURIComponent( this.value ) );\ });\ → When i try to serialize a form in IE it does not work , firefox and Opera work fine. This leads to forms submitted in IE not having the correct fields. \ \ After a little debugging i made a small fix ( works for me in IE , firefox and Opera ) . \ \ in jquery .js after line 2164 i put the following code \ \ var k = false; \ \ if ( a[0][0] != undefined) k = a[0]; \ \ if ( a.constructor == Array || a.jquery || k) \ // Serialize the form elements \ jQuery.each( (k)?k:a, function(){ \ s.push( encodeURIComponent(this.name) + "=" + encodeURIComponent( this.value ) ); \ }); \ \ replacing the original \ \ if ( a.constructor == Array || a.jquery) \ // Serialize the form elements \ jQuery.each( a, function(){ \ s.push( encodeURIComponent(this.name) + "=" + encodeURIComponent( this.value ) ); \ }); \ |
---|---|
milestone: | 1.1.3 → 1.2 |
need: | → Review |
resolution: | → worksforme |
status: | new → closed |
version: | 1.1 → 1.1.4 |
I haven't been able to duplicate this - the new form serialization code in 1.2 should resolve anything here.
What type of form causes this problem in IE?