Adjust caching times for svg images

In the first period we set the caching time for server-side
caching to 1 week and the value for client-side caching
to 1 hour.

Change-Id: Ieab63dfe9a00f31d64945180d7b0d98b9fe62b39
This commit is contained in:
physikerwelt (Moritz Schubotz) 2014-10-15 18:42:20 +02:00
parent f5fbffb8ca
commit ae930172fd

View file

@ -32,7 +32,7 @@ class SpecialMathShowImage extends SpecialPage {
$request->response()->header( "Content-type: image/svg+xml; charset=utf-8" );
}
if ( $success && !( $this->noRender ) ) {
$request->response()->header( 'Cache-Control: public max-age=2419200' ); // 4 weeks
$request->response()->header( 'Cache-Control: public, s-maxage=604800, max-age=3600' ); // 1 week (server) 1 hour (client)
$request->response()->header( 'Vary: User-Agent' );
}
}