CSS Optimization Makes Web Sites Load Faster
CSS Optimization makes your web sites load faster.
What is CSS?
Cascading Style Sheets (CSS) is a stylesheet language used to describe the presentation of a document written in a markup language.
Do your website have a CSS file?
Check your website source code and look for style.css
<link rel=”stylesheet” href=”http://www……com/wp-content/themes/……/style.css” type=”text/css” media=”screen” />
- Go to any one of the online CSS Optimizer, example:
Icey’s CSS Compressor
CleanCSS
CSS Optimizer,
Flumpcakes CSS Optimiser
- Enter your CSS url and optimize it.
- Replace your CSS file with the optimized CSS code.
Compress your optimized CSS file.
- Add before the optimized CSS code.
<?php if(extension_loaded(’zlib’)){ob_start(’ob_gzhandler’);} header(”Content-type: text/css”); ?>
- Add after the optimized CSS code:
<?php if(extension_loaded(’zlib’)){ob_end_flush();}?>
- Save the file as style.css.php
- Edit the file (normally header.php) that contain the line that called for the css file. Change style.css to style.css.php
<link rel=”stylesheet” href=”http://www……com/wp-content/themes/……/style.css.php” type=”text/css” media=”screen” />
- FTP and upload both style.css.php and header.php
Your web sites should load faster than before.
Popularity: 1% [?]
































