It doesn't make a difference to me if my one line gets to ride with 1.4 or not. 
The 'why' is because it was requested and I replied that I had a 1.3.2 copy 
that I had hacked to do this... John mentioned filing a ticket. 

As for my not providing unit test cases, I can simply reply: 9 months real 
world usage in every application that I've written with jquery have proven, to 
me, that it works.

The commit I made to my fork is based on the most recent version of ajax.js in 
the master on github.

The 'how'... Its shockingly simple: it copies the same behaviour as the xml 
detection. Nothing special.

Rick

-- Sent from my Palm Prē
Julian Aubourg wrote:

I'm a bit curious as to how (and why) you intend to implement this, seeing as 
the ajax revamping I've been working on uses an array of dataTypes.

For example s.datTypes = ["jsonp","xml"] means: get an object (a string in that 
case) over jsonp that'll get parsed as xml (and this is actually working and 
being unit tested ;))


If your intention is to give a list of accepted dataTypes, I'd rather go for a 
string of the form "json | xml" if you get my idea.

2009/12/23 webbiedave <webbied...@websiteguard.com>

I'll rewrite so dataType can also accept an array. That way there's

explicitness. I'll report back after some real world usage.





On Dec 23, 3:56 am, Tobias Hoffmann <smilingt...@googlemail.com>

wrote:

> On Wed, Dec 23, 2009 at 5:16 AM, John Resig <jere...@gmail.com> wrote:

> > Is there an open ticket on this? If so I don't see a reason not to land it.

>

> Well, if there is no safe json decoder (i.e. just eval()) it's not

> immediatly clear to me, that I really want this.

> Yes, all the other jscripts also come from the server and are thus somehow

> equally trustworthy.

> And the Content-Type on the HTTP header can not easily be spoofed. But I

> don't want jquery to evaluate some

> unsafe user content (e.g. CMS, Guestbook, ... ) that wasn't ever meant to be

> json ...

>

>   Tobias

>

> > Could we change the $.ajax() function to treat the server's response

> > > as json if dataType is unspecified and the response content-type is

> > > "application/json"?

>

> > > Thanks,

> > > Dave



--



You received this message because you are subscribed to the Google Groups 
"jQuery Development" group.

To post to this group, send email to jquery-...@googlegroups.com.

To unsubscribe from this group, send email to 
jquery-dev+unsubscr...@googlegroups.com.

For more options, visit this group at 
http://groups.google.com/group/jquery-dev?hl=en.












--

You received this message because you are subscribed to the Google Groups 
"jQuery Development" group.


To post to this group, send email to jquery-...@googlegroups.com.


To unsubscribe from this group, send email to 
jquery-dev+unsubscr...@googlegroups.com.


For more options, visit this group at 
http://groups.google.com/group/jquery-dev?hl=en.



--

You received this message because you are subscribed to the Google Groups 
"jQuery Development" group.
To post to this group, send email to jquery-...@googlegroups.com.
To unsubscribe from this group, send email to 
jquery-dev+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/jquery-dev?hl=en.


Reply via email to