Hello all, I have found this code online....
Speed up your website load time by this code
2
Hello all,
I have found this code online....
You have to copy paste it inside .htaccess which is located in file-manager with the rest of your website files.
I have copy pasted it. But a block of code is not under-stable by me..
Here is the block of code I am confused about:
What does this mean, all my css, js, html, xml files will be expired after 7 days from search results/google?
Hope someone expert will describe this full code nicely.
Thanks
I have found this code online....
Code:
Header unset Pragma
FileETag None
Header unset ETag
<IfModule mod_headers.c>
<FilesMatch "\.(js|css|xml|gz)$">
Header append Vary Accept-Encoding
</FilesMatch>
</IfModule>
<FilesMatch "\.(gif|jpg|jpeg|png|ico)$">
ExpiresActive On
ExpiresDefault "access plus 1 month"
</FilesMatch>
<FilesMatch "\.(css|js|html?|xml|txt)$">
ExpiresActive On
ExpiresDefault "access plus 1 week"
</FilesMatch>
# compress text, html, javascript, css, xml:
AddOutputFilterByType DEFLATE text/plain
AddOutputFilterByType DEFLATE text/html
AddOutputFilterByType DEFLATE text/xml
AddOutputFilterByType DEFLATE text/css
AddOutputFilterByType DEFLATE application/xml
AddOutputFilterByType DEFLATE application/xhtml+xml
AddOutputFilterByType DEFLATE application/rss+xml
AddOutputFilterByType DEFLATE application/javascript
AddOutputFilterByType DEFLATE application/x-javascript
# Or, compress certain file types by extension:
<Files *.html>
SetOutputFilter DEFLATE
</Files> I have copy pasted it. But a block of code is not under-stable by me..
Here is the block of code I am confused about:
Code:
<FilesMatch "\.(css|js|html?|xml|txt)$">
ExpiresActive On
ExpiresDefault "access plus 1 week"
</FilesMatch> Hope someone expert will describe this full code nicely.
Thanks
- Dinospider Banned
Next Topics on Trending Feed
-
2