I’ve placed the following code in my CSS file:
<?php ob_start("ob_gzhandler"); header("Content-type: text/css; charset: UTF-8"); header("Cache-Control: must-revalidate"); $offset = 60 * 60 ; $ExpStr = "Expires: " . gmdate("D, d M Y H:i:s", time() + $offset) . " GMT"; header($ExpStr); ?>
As expected, I renamed the extension of the CSS file to that of “.php” but I cannot notice any difference in performance and I think it’s either due to the size of the CSS file or the fact that I’m using WAMP at the moment.
I have the following questions:
1.) What type of overhead can one expect to see be reduced by using this approach?