Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

In the w3 total cache there is the option to set the time until the cache is flushed (and thus, recreated on the next time a visitor comes by).

My question is, assuming I've got a lot of content on my site that doesn't change almost ever, why would I not just set the caching to stay for days (instead of getting flushed every hour or so)?

Is there a problem with that strategy?

share|improve this question

1 Answer 1

up vote 4 down vote accepted

The one possibility is caching broken page. For example some database query fails (which is not uncommon in shared environment and/or under load) and some page gets displayed broken / with errors.

Since caching doesn't assume integrity checking it can cache such page... And your cache interval is days - page is broken as long.

It would work better if mechanism was manual - you explicitly make something static and it remains that way (plenty CMS enginges work completely like that - generate complete static page and serve it). But I am not aware of any WP plugins that implement that.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.