WebsiteBaker 2.13.9 is now available!
R.I.P Dietmar (luisehahne) and thank you for all your valuable work for WBhttps://forum.websitebaker.org/index.php/topic,32355.0.html
## EXPIRES CACHING ##<IfModule mod_expires.c>ExpiresActive OnExpiresByType image/jpg "access plus 1 year"ExpiresByType image/jpeg "access plus 1 year"ExpiresByType image/gif "access plus 1 year"ExpiresByType image/png "access plus 1 year"ExpiresByType text/css "access plus 1 month"ExpiresByType application/pdf "access plus 1 month"ExpiresByType text/x-javascript "access plus 1 month"ExpiresByType application/x-shockwave-flash "access plus 1 month"ExpiresByType image/x-icon "access plus 1 year"ExpiresDefault "access plus 2 days"</IfModule>## EXPIRES CACHING ##
<?php//"Sandkasten" 08.Jan.2018//Template cache for static files$url = $_SERVER["SCRIPT_NAME"];$break = Explode('/', $url);$file = $break[count($break) - 1];//$cachefile =$_SERVER['DOCUMENT_ROOT'].PAGES_DIRECTORY.'/'. 'iscached-'.substr_replace($file ,"",-4).'.html';$cachefile =$_SERVER['DOCUMENT_ROOT'].PAGES_DIRECTORY.'/'. ''.substr_replace($file ,"",-4).'.html';//$cachefile =$_SERVER['DOCUMENT_ROOT'].'/'. 'iscached-'.substr_replace($file ,"",-4).'.html';//$cachefile =$_SERVER['DOCUMENT_ROOT'].'/'. ''.substr_replace($file ,"",-4).'.htm';$cachetime = 18000;// Serve from the cache if it is younger than $cachetimeif (file_exists($cachefile) && time() - $cachetime < filemtime($cachefile)) { echo "<!-- Cached copy, generated ".date('H:i', filemtime($cachefile))." -->\n"; include($cachefile); exit;}ob_start();?><html><body>..............................</body></html><?php$fp = fopen($cachefile, 'w');fwrite($fp, ob_get_contents());fclose($fp);ob_end_flush(); ?>