southill
11/26/2017 - 4:46 AM

php2html.php

php2html.php

<?php
    ob_start();
    error_reporting(0);
    require_once('../index.php');
    $content = ob_get_contents();//取得php页面输出的全部内容
    $fp = fopen("../index.html", "w");
    fwrite($fp, $content);
    fclose($fp);
    header('Location:../index.html');
?>