in reply to Re: Document Size
in thread Document Size

Beware that the Content-Length header is optional though, and many dynamic documents will not output it. Also, some servers tend to do different things with it depending on the request method:

% HEAD http://www.cnn.com/ 200 OK Cache-Control: private,max-age=60 Connection: close Date: Fri, 05 Oct 2001 08:14:42 GMT Server: Netscape-Enterprise/4.1 Content-Length: 0

Then there is the case of servers which will not handle HEAD requests. In the end the only guaranteed way is to use GET and length().