X-Git-Url: https://git.harvie.cz/?a=blobdiff_plain;ds=sidebyside;f=lib%2FBarcode.class.php;fp=lib%2FBarcode.class.php;h=6b2ed5613bbf66a3b1adb3c1fb4e98eff132205e;hb=c6712080cfa133be17ae8e6ee18d7d009766978c;hp=b4231e660bffe34e80671feb01882ae788c7cf9d;hpb=19cbf1cb4937423b899c110a020c3399f4e5032e;p=mirrors%2FSokoMan.git diff --git a/lib/Barcode.class.php b/lib/Barcode.class.php index b4231e6..6b2ed56 100755 --- a/lib/Barcode.class.php +++ b/lib/Barcode.class.php @@ -51,7 +51,10 @@ class Barcode { } static function download_barcode($string='EXAMPLE', $convert='png', $enctype='code128b') { - if(self::test()) header('Content-Type: image/png'); else die(); + if(self::test()) { + header('Content-Type: image/png'); + header('Cache-Control: max-age=604800, public'); //1week caching + } else die(); die(self::cached_barcode($string,$convert,$enctype)); } }