diff --git a/apps/gallery/ajax/galleryOp.php b/apps/gallery/ajax/galleryOp.php index 0ec447d01f68d0745a1a4e8df63397ab57bbc4d6..8df692c77351e63e6bd000be183efbcf96968686 100644 --- a/apps/gallery/ajax/galleryOp.php +++ b/apps/gallery/ajax/galleryOp.php @@ -45,6 +45,11 @@ function handleGetThumbnails($albumname) { OC_JSON::checkLoggedIn(); $photo = new OC_Image(); $photo->loadFromFile(OC::$CONFIG_DATADIRECTORY.'/../gallery/'.$albumname.'.png'); + $offset = 3600 * 24; // 24 hour + // calc the string in GMT not localtime and add the offset + header("Expires: " . gmdate("D, d M Y H:i:s", time() + $offset) . " GMT"); + header('Cache-Control: max-age='.$offset.', must-revalidate'); + header('Pragma: public'); $photo->show(); }