[jquery-dev] using optional data arg to $.getJSON with jsonp callback

2009-07-18 Thread Matthew M. Boedicker
I like passing query string params to $.getJSON as an array using the optional data argument because it's more readable. However when using a jsonp callback parameter it gets encoded to callback=%3F, causing it to fail. Any way to accomplish this without modifying jquery? This patch to jquery

[jquery-dev] Option to prevent encoding by $.ajax and $.param?

2009-11-20 Thread Marco Rogers
This is essentially a proposal for an enhancement to the two named functions: I ran into an issue today when sending parameters with the ajax function. If the data option is set, $.param is used to encode and format the keys and values into a query string. But some of the values in my data were

[jquery-dev] Re: Option to prevent encoding by $.ajax and $.param?

2009-11-20 Thread Marco Rogers
: This is essentially a proposal for an enhancement to the two named functions: I ran into an issue today when sending parameters with the ajax function.  If the data option is set, $.param is used to encode and format the keys and values into a query string.  But some of the values in my data were

[jquery-dev] Re: Option to prevent encoding by $.ajax and $.param?

2009-11-24 Thread Cowboy Ben Alman
function.  If the data option is set, $.param is used to encode and format the keys and values into a query string.  But some of the values in my data were already encoded and hence got double encoded. It was not easy to determine which params had been pre-encoded and which hadn't

[jquery-dev] Re: Option to prevent encoding by $.ajax and $.param?

2009-11-23 Thread Marco Rogers
for an enhancement to the two named functions: I ran into an issue today when sending parameters with the ajax function.  If the data option is set, $.param is used to encode and format the keys and values into a query string.  But some of the values in my data were already encoded and hence got

[jquery-dev] Re: Option to prevent encoding by $.ajax and $.param?

2009-11-24 Thread Marco Rogers
parameters with the ajax function.  If the data option is set, $.param is used to encode and format the keys and values into a query string.  But some of the values in my data were already encoded and hence got double encoded. It was not easy to determine which params had been pre

[jquery-dev] Re: using optional data arg to $.getJSON with jsonp callback

2009-07-18 Thread John Resig
I understand your point but I think it might work better if the jsre regexp was tweaked, instead: jsre = /=(\?|%3F)(|$)/g Does making the above change work for you? --John On Fri, Jul 17, 2009 at 8:41 PM, Matthew M. Boedicker matth...@boedicker.org wrote: I like passing query string

[jquery-dev] Re: using optional data arg to $.getJSON with jsonp callback

2009-07-18 Thread Matthew M. Boedicker
regexp was tweaked, instead: jsre = /=(\?|%3F)(|$)/g Does making the above change work for you? --John On Fri, Jul 17, 2009 at 8:41 PM, Matthew M. Boedicker matth...@boedicker.org wrote: I like passing query string params to $.getJSON as an array using the optional data argument

[jquery-dev] Re: using optional data arg to $.getJSON with jsonp callback

2009-07-18 Thread John Resig
= /=(\?|%3F)(|$)/g Does making the above change work for you? --John On Fri, Jul 17, 2009 at 8:41 PM, Matthew M. Boedicker matth...@boedicker.org wrote: I like passing query string params to $.getJSON as an array using the optional data argument because it's more readable. However when using

[jquery-dev] Re: using optional data arg to $.getJSON with jsonp callback

2009-07-18 Thread Matthew M. Boedicker
query string params to $.getJSON as an array using the optional data argument because it's more readable. However when using a jsonp callback parameter it gets encoded to callback=%3F, causing it to fail. Any way to accomplish this without modifying jquery? This patch to jquery made it work