httpd.conf 相关部分改为如下
加载模块 LoadModule include_module libexec/apache2/mod_include.so
AddType text/html .shtml
AddOutputFilter INCLUDES .html(如果是.shtml就是支持shtml)
Options Indexes FollowSymLinks includes
使用语法
<!--#include virtual="test.html"-->
文件不存在将报一下错误 [an error occurred while processing this directive]
转载于:https://blog.51cto.com/liyongjiang/1163449