My web application is delivering an AJAX request to the server using jQuery, reacting in possibly large textual data. I am using Apache and would really like this data to become compressed throughout the transport with mod_deflate. While mod_deflate is set up on my small server and works best for most text message, it does not appear to utilize AJAX demands. I have in comparison the request headers originating from "regular" demands and from XHR, and also the only difference is the fact that with AJAX I am delivering one more header:

X-Requested-With: XMLHttpRequest

In the two cases, I am delivering

Accept-Encoding: gzip, deflate

(and again, other headers will also be identical) Therefore it appears like Apache selects to prevent blending whether it receives this header. What exactly I'm doing wrong? Could it be a configuration problem around the Apache side? I suppose I'm able to hack and take away the X-Asked for-With header, but I am unsure the "right" approach to take..

Thanks, Yaniv

I believe this link may be of outside assistance: http://www.ruby-forum.com/topic/121716