BUGFIX: Added X-Forwarded-Protocol and User-Agent to Vary header.

This commit is contained in:
Sam Minnee 2011-07-07 17:28:58 +12:00
parent b63e55a77a
commit b114aa2488

View File

@ -287,6 +287,10 @@ class HTTP {
if(self::$cache_age > 0) {
$responseHeaders["Cache-Control"] = "max-age=" . self::$cache_age . ", must-revalidate";
$responseHeaders["Pragma"] = "";
// To do: User-Agent should only be added in situations where you *are* actually varying according to user-agent.
$responseHeaders['Vary'] = 'Cookie, X-Forwarded-Protocol, User-Agent';
} else {
$responseHeaders["Cache-Control"] = "no-cache, max-age=0, must-revalidate";
}