• Resolved Deon

    (@deon-b)


    Hello!
    Before installing LSCache I had the following rules in my .htaccess file:

    RewriteRule ^\.well-known\/acme-challenge\/ - [L]
    ## EXPIRES CACHING ##
    <IfModule mod_expires.c>
    ExpiresActive On
    ExpiresByType image/jpg "access plus 1 year"
    ExpiresByType image/jpeg "access plus 1 year"
    ExpiresByType image/gif "access plus 1 year"
    ExpiresByType image/png "access plus 1 year"
    ExpiresByType text/css "access plus 1 month"
    ExpiresByType application/pdf "access plus 1 month"
    ExpiresByType text/x-javascript "access plus 1 month"
    ExpiresByType application/x-shockwave-flash "access plus 1 month"
    ExpiresByType image/x-icon "access plus 1 year"
    ExpiresDefault "access plus 2 days"
    </IfModule>
    
    ## EXPIRES CACHING ##
    # compress text, HTML, JavaScript, CSS, and 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
    
    <ifModule mod_gzip.c>
    mod_gzip_on Yes
    mod_gzip_dechunk Yes
    mod_gzip_item_include file .(html?|txt|css|js|php|pl)$
    mod_gzip_item_include handler ^cgi-script$
    mod_gzip_item_include mime ^text/.*
    mod_gzip_item_include mime ^application/x-javascript.*
    mod_gzip_item_exclude mime ^image/.*
    mod_gzip_item_exclude rspheader ^Content-Encoding:.*gzip.*
    </ifModule>

    Now that I installed LSCache I have a question:

    1) These rules are still in the .htaccess file, are they compatible with LScache?

    2) I am using the default LSCache settings, how does the default caching provided by the plugin differ from the caching those rules were providing?

    i.e. I’m thinking whether for a basic user the plugin is useful or not, and if maybe I would be better off just with the htaccess rules and less plugins, or if the difference is big. I don’t know any place to get this data to compare the options / performance and make a decision.

Viewing 8 replies - 16 through 23 (of 23 total)
  • Plugin Support qtwrk

    (@qtwrk)

    I have seen some users enable expire header and cache-control header over dynamic page , this will cause the browser to cache the page and result in out-dated content when user update the post/page

    so that warning also warns this kind of scenario

    Thread Starter Deon

    (@deon-b)

    Hi @qtwrk
    Thank you for sticking with me on this thread ??

    I have seen some users enable expire header and cache-control header over dynamic page , this will cause the browser to cache the page and result in out-dated content when user update the post/page

    I don’t know what you mean by this, I guess I am missing a few basic pieces of knowledge to make sense of this answer.

    But for my case:
    https://url.dev/zLgq9ut/
    Should I keep or remove this line: ExpiresDefault "access plus 2 days" from .htaccess or not (considering I have browser caching disabled in LSC settings)?

    I suppose my content is not dynamic (maybe just the poll is but we already put the exception for that so I guess it doesn’t count?)

    Plugin Support qtwrk

    (@qtwrk)

    please provide me the report number , you can get it in toolbox -> report -> click “send to LiteSpeed”

    it will carry the entire htaccess content , let me review the whole content first.

    Thread Starter Deon

    (@deon-b)

    Hi!
    Here’s the report number:
    QWUXGZOV

    Thanks!

    Plugin Support qtwrk

    (@qtwrk)

    it looks like does not matter if you remove it or keep it , you have cache-control header over your main request.

    Thread Starter Deon

    (@deon-b)

    Hmmm, do you mean it’s good as it is, or you mean that I would be better off changing it?

    Code I have in my .htaccess is stuff I have been adding over the years, while using different plugins, so I don’t know how that is matching with LSCache.

    Plugin Support qtwrk

    (@qtwrk)

    ExpiresDefault "access plus 2 days" this directive does NOT matter if you keep it or not

    Thread Starter Deon

    (@deon-b)

    I have another question about a different topic. I will open a new thread.

Viewing 8 replies - 16 through 23 (of 23 total)
  • The topic ‘Compatibility with htaccess rules?’ is closed to new replies.