[Javascript] Resizing images client-side

Hassan Schroeder hassan at webtuitive.com
Fri Jul 13 15:56:56 CDT 2007


Glenn E. Lanier, II wrote:

> I think you can look in the POST/GET headers to see the size of the data
> envelope in most languages. I know C++ based ISAPI allows you to access this
> information before receiving the entire POSTed info 

A user-agent SHOULD (per the RFC) provide a Content-Length header,
but it's not *required*, nor if it exists can you count on it being
accurate :-)

And if, at the point the header is available, you read it and close
the connection, there will still have already been a lot of data on
the wire, so bandwidth will have been (pointlessly) consumed, which
appeared to be the original concern.

-- 
Hassan Schroeder ----------------------------- hassan at webtuitive.com
Webtuitive Design ===  (+1) 408-938-0567   === http://webtuitive.com

                            dream.  code.




More information about the Javascript mailing list