tp6 tpl_replace_string设置 应用下配置view.php

以前一直用thinkcmf,此次由于特别须要,得用tp6,从头作一套cms系统php

多应用模式配置好以后,在须要配置的应用目录下新建config目录,视图这里是view.php,以前一直用config.php,结果各类不生效。
在这里插入图片描述
而后配置好tpl_replace_string缓存

return [
 
    'tpl_replace_string' => [
        '__STATIC__'=>'/static',   
    ],
    // 是否开启模板编译缓存,设为false则每次都会从新编译
    'tpl_cache'          => false, 
];
相关文章
相关标签/搜索