Personal tools
You are here: Home   Bugs   Add "X-Requested-With"  
 
Document Actions

#25 — Add "X-Requested-With"

State Unconfirmed
Release: 1.2 (Zope 2.10)
Area Client side framework and general
Issue type Patch
Severity Medium
Submitted by Walter Cruz
Submitted on 2008-03-17
Responsible
Target release:
Return to tracker
Last modified on 2008-03-17 by Walter Cruz
Hi. I'm using kss.base and kss.pylons. Just one point: the serveraction.js doesn't set the "X-Requested-With". Although is not a standart, jquery and prototype sets this property to XMLHttpRequest to say that the request is a XMLHttpRequest. Pylons can verify if a request is XMLHttpRequest by verifying if request.is_xhr is True. I think that another frameworks can use this property to.

Just add:
    domDoc.setRequestHeader("X-Requested-With", "XMLHttpRequest");

befor:
domDoc.send(encoded);