Mengatasi Leverage browser caching dan Mempercepat website
Asslamualaikum sobat
Beberapa saat yang lalu saya mengukur kecepatan website saya di pingdom.com disana ada permasalahan di Leverage browser caching dengan nilai 0..ini maksudnya apabila website anda dibuka,maka akan disimpan di chace browser,sehingga apabila dibuka lagi,akan tidak akan membutuhkan waktu yang lama...masalah ini membuat kecepatan website saya down,,rupanya masalah ini bisa diatasi dengan menambah kan tag dibawah...copykan ke .htaccess pada file hosting anda,,,copykan pada paling atas
Sebelum
## EXPIRES CACHING ##
<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType image/jpg "access 1 year"
ExpiresByType image/jpeg "access 1 year"
ExpiresByType image/gif "access 1 year"
ExpiresByType image/png "access 1 year"
ExpiresByType text/css "access 1 month"
ExpiresByType text/html "access 1 month"
ExpiresByType application/pdf "access 1 month"
ExpiresByType text/x-javascript "access 1 month"
ExpiresByType application/x-shockwave-flash "access 1 month"
ExpiresByType image/x-icon "access 1 year"
ExpiresDefault "access 1 month"
</IfModule>
## EXPIRES CACHING ##
<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType image/jpg "access 1 year"
ExpiresByType image/jpeg "access 1 year"
ExpiresByType image/gif "access 1 year"
ExpiresByType image/png "access 1 year"
ExpiresByType text/css "access 1 month"
ExpiresByType text/html "access 1 month"
ExpiresByType application/pdf "access 1 month"
ExpiresByType text/x-javascript "access 1 month"
ExpiresByType application/x-shockwave-flash "access 1 month"
ExpiresByType image/x-icon "access 1 year"
ExpiresDefault "access 1 month"
</IfModule>
## EXPIRES CACHING ##
0 komentar :
Post a Comment