compression - Get compressed and uncompressed page size with PHP -


http://www.gidnetwork.com/tools/gzip-test.php great tool, need test site behind walls , want find similar results: compression type, markup size, compressed page size, , compression ratio.

how can both compressed , uncompressed page sizes? better method fetching data (file_get_contents() or curl)?

the response headers contain else needed - i'm not sure sizes.

you have use curl there 2 reasons so:

  1. as need headers of request , can have through curl easily

  2. file_get_contents() used internally include things , not external source fetch data. if used external purposes there issue memory limit, size etc. have taken great care of.


Comments

Popular posts from this blog

Issues changing the value of an element in an array in matlab -

php - MySQLi binding parameters in a prepared statement doesn't work unless inserted after "WHERE" -

vb.net - Alternative to the T-SQL AS keyword -