Skip to main content

Bug Tracker

Side navigation

#9360 closed bug (duplicate)

Opened May 20, 2011 08:19AM UTC

Closed May 20, 2011 02:36PM UTC

Last modified May 20, 2011 02:37PM UTC

Changed behavior of $.param()

Reported by: genuinebastard@gmail.com Owned by:
Priority: undecided Milestone: 1.next
Component: unfiled Version: 1.6.1
Keywords: Cc:
Blocked by: Blocking:
Description

In version 1.6.1 $.param() seems to omit empty arrays, so for example:

var obj = { a: 1, b: [] };

console.log($.param(obj));

prints out: a=1

In version 1.5.2 the result would be: a=1&b=

This causes problems with ajax requests etc.

Attachments (0)
Change History (3)

Changed May 20, 2011 02:36PM UTC by dmethvin comment:1

resolution: → duplicate
status: newclosed

Duplicate of #6481, see the discussion there and in this forum thread: http://forum.jquery.com/topic/change-of-behavior-in-1-4-4-because-of-bug-6481

Changed May 20, 2011 02:36PM UTC by dmethvin comment:2

Duplicate of #6481.

Changed May 20, 2011 02:37PM UTC by timmywil comment:3

#9348 is a duplicate of this ticket.