Cache Question

  • Hello everyone!

    Im using WoltLab for 1 year now, But I got the following problem

    I am changing header frequently if you open Google Chrome after the change every user is forced to manually do cache clear for website.
    I don't really like this, I would like to keep my cache for everything but still needs to load the new header images or other changes

    Anyway to force this? With plugin or cronjobs?

    To make it refresh for everyone.

    When opening incognito it shows the changes but when opening chrome the normal way it still loads the old images etc.


    Regards,
    Jeremy

  • Hello,


    The caching is enforced via a HTTP header set by the webserver itself. You can either set headers with a short cache duration for the particular file, for example, via .htaccess, or use different filenames for each header image.


    If you're using the same images but rotate them regularly, I would recommend to use distinctive file name. You would achieve both an instantaneous update of the displayed image while still making use of the browser cache to reduce traffic for both you and your users.

    Alexander Ebert
    Senior Developer WoltLab® GmbH

  • Hello,


    The caching is enforced via a HTTP header set by the webserver itself. You can either set headers with a short cache duration for the particular file, for example, via .htaccess, or use different filenames for each header image.


    If you're using the same images but rotate them regularly, I would recommend to use distinctive file name. You would achieve both an instantaneous update of the displayed image while still making use of the browser cache to reduce traffic for both you and your users.

    Hey thanks for your reply!

    Is it possible to do this with a cronjob?

  • Really, this has absolutely nothing to do with the software and cannot be solved in PHP. This is purely about your webserver configuration!

    Alexander Ebert
    Senior Developer WoltLab® GmbH

  • The easiest way would be in using different file names for different headers to force the cache to be reloaded.

    Plugins, Designs, Hosting, Support und mehr: KittMedia