httpd-modules-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joe Lewis <...@joe-lewis.com>
Subject Re: one question about HTTP response header "Content-Length"
Date Fri, 16 Mar 2012 06:48:27 GMT
On 3/16/12 12:31 AM, Rui Hu wrote:
> I have another question. I found that not every request's response header
> has field of "Content-Length", is it normal?

That depends on what "normal" is.  You are probably looking at what the 
content generators have provided, and the generators don't always set 
that.  You might find that cgi's may or may not have the header.  There 
are other modules hooking into things that alter the content even more, 
e.g. chunking and gzipping to name some examples of content being 
altered, and therefor, the headers having to be altered.

If what you want is the served content length header, you might even 
consider hooking in a logging hook that provides the setting.

> Additionally, can I modify HTTP response header in output filter of
> AP_FTYPE_PROTOCOL type?
Probably.  I would only modify that if you were using an output filter 
(e.g. compression, again).

Joe
--
http://www.silverhawk.net/

Mime
View raw message