Support » Plugin: LiteSpeed Cache » Separate caching for subdomains

  • Resolved



    I am referring to this site:

    When you change the language with one of the buttons in the upper right corner you will see the languages opens in a subdomain. for German – as an example.

    I see now this issue: Because I can very accurate do the SEO for each language I use in the title the placeholder $$COUNTRY$$ which is replaced like that [simplified]:

    add_action( 'template_redirect', function(){
        ob_start( function( $buffer ) {
            // depending on the subdomain replace ''$COUNTRY$$ by the country name
    	$buffer = str_replace( '$$COUNTRY$$', 'UK England', $buffer );
            return $buffer;

    So, when the site is running a while in the cached mode I see that the $$COUNTRY$$ placeholder isn’t replaced correctly.

    It looks to me like LSCWP is delivering the same content also for different subdomains.

    How is it? Am I right, or do I have to set something, so each subdomain [,, …] is considered separately or is delivered for each subdomain the cached content from the main domain?

    I hope you understand what I mean. Just click around and check the title for the pages. Usually in the title should be the country of the select language but after a while only UK England appears even before it was correctly.


Viewing 7 replies - 1 through 7 (of 7 total)
  • That you better understand what I mean, I provide you 2 examples:

    Due to the fact that ‘UK England’ is replacing the $$COUNTRXY$$ placeholder only in the above function, it is obvious that LSCWP is returning the cached content also for the subdomain.

    When I disable caching then all works fine.

    Sorry, the above URL is not for Spanish, it is for Slovak version of the site. However, also here there is the same problem:
    ‘kúpiť Online UK Anglicko CBD náplasti bez prášku’
    The bold text is in Slovak ‘UK England’ but this is of course wrong as this is the Slovakian subdomain the country should be replaced to ‘Slovensko’ what is in Slovak Slovakia.

    For the previous thread the correct URL is: and there is the above described issue.

    I had to move my site from shared server to VPS. I am now activating LiteSpeed Server so for the moment the site is without the caching functions and you won’t see the issue. I will let you know once I have activated it.

    Plugin Support LiteSpeed Lisa



    Yes, please do let us know once you have activated LSCache so we can take a look.

    I opened a ticket in LiteSpeed ticket system. Because of Google and the incorrect content I don’t want to active the cache now.

    My timezone is CET – so now I have 15:25. Can you tell me a time in UTC when you can check it?

    I would activate it few minutes before so you find the incorrect content and you write me few minutes later so I can deactivate it?

    Plugin Support LiteSpeed Lisa


    Ah, ok. If you opened a ticket, then it’s best to just close this topic here, and continue via the ticket system, so we don’t duplicate any effort.

Viewing 7 replies - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.