I\'m building a REST API.. Sometimes the server returns the response with chunked transfer encoding? Why is that?!
Why can\'t the server always return the response in
A problem may be that Apache is gzipping your download, taking care of correcting the Content-Length, or in your case, adding the header
Content-Encoding: chunked
You can add a .htaccess RewriteRule to disable gzip:
.htaccess
RewriteRule . - [E=no-gzip:1]