dedecms 模板静态化

    require_once (dirname(__FILE__) . "/../include/common.inc.php");
    require_once DEDEINC."/arc.partview.class.php";


    $row['templet'] = '../m/index_m.html';
    $pv = new PartView();

    if ( !file_exists($row['templet']) )
    {
        echo "模板文件不存在,无法解析文档!";
        exit();
    }
    $pv->SetTemplet($row['templet']);
    $row['showmod'] = 1;
    if ($row['showmod'] == 1)
    {
        $pv->SaveToHtml('../m/index.html');
        ShowMsg('更新wap主页成功...','../m/index.html',1,5000);
        echo "
            <a href='http://member.wufun.net/m/index.html' target='_blank'>点击浏览wap主页</a>
        ";
        exit();
    }

 

posted on 2016-10-19 14:33  沧海一滴水  阅读(145)  评论(0编辑  收藏  举报