Caching HTML output with PHP

后端 未结 8 1474
时光说笑
时光说笑 2020-12-19 21:03

I would like to create a cache for my php pages on my site. I did find too many solutions but what I want is a script which can generate an HTML page from my database ex:

8条回答
  •  情深已故
    2020-12-19 21:08

    check ob_start() function

    ob_start();
    echo 'some_output';
    $content = ob_get_contents();
    ob_end_clean();
    
    echo 'Content generated :'.$content;
    

提交回复
热议问题