Invision Community 4: SEO, prepare for v5 and dormant account notifications Matt November 11, 2024Nov 11
Posted June 5, 201510 yr Hi folks.Would appreciate your insight. A few years ago I added the following lines of code to the first lines of all my PHP/Xhtml Transitional based web pages (nothing to do with IPS Suite).<?php ob_start( 'ob_gzhandler' ); ?>I also renamed by CSS sheets to end in php file extention and added these lines of code to them, so that they would be gzipped as well:<?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); ?> These 2 actions gave some great compression and speed reduction results on my websites. Due to increasing work commitments, I haven't been able to keep up to date with web design/development as I used to, and I'm catching up. Is this still the best way to do it? Or has it been superseded by newer best practice methods like using .htacess?Many thanks.Regards,Graham
June 5, 201510 yr Use server-side driven compression techniques, much faster and less resources taken up
Archived
This topic is now archived and is closed to further replies.