ostark / upper

Integrates Edge Caches like Fastly, KeyCDN, Cloudflare and Varnish with Craft.
MIT License
102 stars 22 forks source link

Tuning with CloudFlare #21

Closed JamesNuttall closed 5 years ago

JamesNuttall commented 5 years ago

I have a few pages on my site that are very dynamically heavy therefore I would like to disable caching for those pages. I have tried including the follow cache header as stated in the docs:

{% header "Cache-Control: private, no-cache" %}

But CloudFlare seems to be ignoring the header, or it is being overwritten by something as the pages with that header are still getting cached and when viewing in the network tab have the following header present: cache-control: public, max-age=43200.

Setup/Config:

Im not sure if its my ignorance on the subject to wether this is something that is possible, if I have setup something incorrectly or wether this is an issue with the plugin. Any help would be greatly appreciated. Thanks.

JamesNuttall commented 5 years ago

I believe I have fixed this, Issue with the setup of CloudFlare. Sorry for the inconvenience.

ostark commented 5 years ago

@JamesNuttall this setting?

Cache > Browser Cache Expiration > Respect Existing Headers
JamesNuttall commented 5 years ago

@ostark I changed a few things, but yes I believe so.