RE: AJAX and CT Proxies

Hi,

Do you really need a new header? If some entity in delivery chain issue a new HTTP request saying

Accept: application/xml; application/json

it should be considered as something not to be transcoded. I think this is more consistent with the HTTP protocol design. This approach it is also friendly and consistent with requests coming from J2ME clients, which should also be taken into account.

If you flag requests coming from the XMLHttpRequest object you will still face the following problem:

Imagine you are using the XMLHttpRequest mechanism to inject some HTML code in your page. In that case the request comes from the XMLHttpRequest mechanism but a transcoding proxy might be useful to adapt that HTML code that it is the result of the XMLHttpRequest.

It seems to me that some kind of mechanism based on accept headers could be the most flexible approach

Best Regards

________________________________________
De: public-bpwg-ct-request@w3.org [public-bpwg-ct-request@w3.org] En nombre de Sean Patterson [SPatterson@Novarra.com]
Enviado el: miércoles, 30 de abril de 2008 21:27
Para: public-bpwg-ct
Asunto: AJAX and CT Proxies

Re: our discussion of how to detect that a request is really an XHR.

According to this blog post: http://www.dev411.com/blog/2006/06/30/should-there-be-a-xmlhttprequest-user-agent, at least one of the JS libraries out there (Prototype) uses the X-Requested-With header to indicate that the request is an XHR.  Evidently Dojo and MochiKit don’t send any identifying headers at all, although some people are manually adding some.  The author of the post is proposing an “X-Ajax-Engine” to identify XHR requests.

This post is from 2006, so I’m not sure what the state of affairs is currently, but I wanted to point out that there seem to be some other people thinking about this issue.

Sean

Received on Wednesday, 30 April 2008 20:19:49 UTC