On 9/21/2012 12:44 PM, edward eric pedersson wrote: > Thanks for your response Ben.
Sure! > I did mean the user-agent caching. I guess I can control this using the > PHP header output and hope the user-agent respects the header. > > Penalties or benefits, depends which way you look at it I guess ;-) > > Essentially I need to compare the cost of the two statements below > assuming a 20K - 50K file > > <link rel="stylesheet" > type="text/css" > href="http://my.domain.com/stylesheet.php?file=/path/to/stylesheet.css"/> > <link rel="stylesheet" > type="text/css"href="http://my.domain.com/path/to/stylesheet.css > <http://my.domain.com/stylesheet.php?file=/path/to/stylesheet.css>"/> > > The first one uses a PHP file to get output compression (as described in > my previous email - simply loading the file and returning it with > compression using ob_gzhandler). > The second does the usual. > > All things being equal, which one will load faster? I'll be surprised if anyone is able to provide an authoritative answer here. There are a number of factors that contribute to how PHP performs in a given environment. You may just have to benchmark it. That said, I suspect that using PHP to gzip the stylesheets will yield a faster page-load time than not compressing them at all, given the file-sizes you describe. > I can try and get a few tests running but I will hold off in case anyone > here knows already. Please do share the results if you elect to perform benchmarking. I'm curious :). Thanks, -Ben --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org For additional commands, e-mail: users-h...@httpd.apache.org