WebsiteBaker 2.13.8 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
<?php//$cacheFile=$_SERVER['DOCUMENT_ROOT']."/wb/pages/".constant('MENU_TITLE').".html";$cacheFile=$_SERVER['DOCUMENT_ROOT']."/htmlout/".constant('MENU_TITLE').".html";if (file_exists($cacheFile)) //we can read this cache file back reduce database load{header("Content-Type: text/html");readfile($cacheFile);exit;} else {ob_start(); //start buffering so we can cache for future accesses}?><html><body><content>Hello, World!</content></html></body> <?php// get the buffer$buffer = ob_get_contents();// end output buffering, the buffer content// is sent to the clientob_end_flush();// now we create the cache file$fp = fopen($cacheFile, "w");fwrite($fp, $buffer);fclose($fp);?>
https://forum.WebsiteBaker.org/index.php/topic,14663.msg92478.html#msg92478