Using Cache Browser (Leverage Browser Caching)

Using Cache Browser (Leverage Browser Caching)
menggunakan cache pada browser pengunjung 
What is cache in the browser? Browser cache is a temporary storage system for static files that are used on a web page with the aim of speeding up the loading time of the web page.

So what is meant by LEVERAGE BROWSER CACHING is to give instructions to your browser about how to treat each type of file on your web page.

When you open a web page, your browser will contain things like logos, CSS, javascript, etc.

What the cache browser does is "remember" the resources of a web page that has been loaded by the browser. So if visitors open another page, then the browser no longer needs to load the basic elements of your web page.

This is what makes the first page load time longer than loading time when opening other pages from the same website. So using a cache will speed up the loading time of repeat visitors on your website.

Make sure you know how to make the website use the cache in the user's browser optimally.

You can find out if your website has a browser cache system using GTMETRIX.

gtmetrix dengan leverage browser caching bermasalah
 
How to use the browser cache
 
The easiest way to make your website use cache in a browser is to use an .htaccess file on your website ....

  •     So please enter your cpanel and look for the file manager or file manager.
  •     Go to public_html and look for the .hataccess file then right-click and select edit
  •     Enter the following code at the top of the .htaccess file

    ## EXPIRES CACHING ##
    <IfModule mod_expires.c>
    Expires Active 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"
    ExpiresByText / css type "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"
    Expires Default "access 1 month"
    </ IfModule>
    ## EXPIRES CACHING ##

  •     If you have saved the changes ...


If this is done correctly, there should be no problems with LEVERAGE BROWSER CACHING for your website.

Attention!
 
Set a minimum caching time of 1 month (1 month) and a maximum of 1 year (1 year). You also need to know that using cache means that it is possible for visitors to load the cached version even if you have updated it.
Be careful using the cache system on websites that use interactive scripts such as shopping carts, because the browser might load cached calculations instead of correct calculations.

If the results are not 100%, the website uses too much resources from third parties, which is beyond our authority to regulate the cache. But usually this file is small so it's not a serious problem ...

0 Response to "Using Cache Browser (Leverage Browser Caching)"

Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel