Feature #16731
closedCache-Control Headers do not address client-side caching
0%
Description
I am struggling to prevent my friend the IE from caching locally...
Normally, that is done using HTTP headers. TYPO3 supports these with the "sendCacheHeaders" config option, and it behaves just like TSRef says: "In case caching is not allowed, these headers are sent to avoid client caching: Cache-Control: private"
Now "Cache-Control: private" is fine for shared proxy caches but not for client side caching (see http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html).
What it takes is to send additional headers, at least "Expires:"
(There are other options that could be used, while this one is preferred.)
To address all purposes (enable or disable client caching), IMHO the behaviour should be toggable.
Funny thing is, that in class.t3lib_userauth.php an internal variable called "sendNoCacheHeaders" seems to take care of this issue.
Extending this concept to a TS switch for class.tslib_fe.php is solving the problem - patch is attached.
Bottom line is:
sendNoCacheHeaders = 0 : prevent shared (a.k.a. proxy) caching, allow client (a.k.a. browser) caching. This was Ole Tange's sole intention when introducing sendCacheHeaders, as he just told me.
sendNoCacheHeaders = 1 : prevent all caching
[Another option would be to change "sendCacheHeaders" (without the "No") from boolean to multiple value or even bitmask, but I'd tend to avoid this.]
(issue imported from #M4541)
Files
Updated by Martin Kutschker about 18 years ago
I suggest to go the usual TYPO3 way. Make config.sendNoCacheHeaders a pseudo boolean.
So 1 means what it means today: prevent shared caching (proxy)
And 2 means: prevent private caching (client)
Updated by Ekkehard G¼mbel about 18 years ago
Are you talking of config.sendCacheHeaders (without the "No")?
Updated by Peter Niederlag almost 18 years ago
Some additional info can be found in this thread from dev-list:
http://lists.netfielders.de/pipermail/typo3-dev/2006-November/020767.html
Updated by Vladimir Podkovanov almost 15 years ago
Hi, any news on this issue?
I'm running into that Opera 9.0 caches pages and does not check them again unless no-cache header was manually sent at first place (has no such issue with FF and IE).
I get it fixed with config.additionalHeaders = Expires: 0|Cache-Control: no-cache, must-revalidate|Pragma: no-cache
But would be more handy to send all those headers automatically (really as Ekkehard Gümbel wrote there are "no cache" headers in class t3lib_userAuth, just config option should be added to triger them).
Updated by Alexander Opitz over 11 years ago
- Category deleted (
Communication) - Status changed from New to Needs Feedback
- Target version deleted (
0) - PHP Version deleted (
4)
The issue is very old, does this issue exists in newer versions of TYPO3 CMS (4.5 or 6.1)?
Updated by Alexander Opitz about 11 years ago
- Status changed from Needs Feedback to Closed
No feedback for over 90 days.