如果你的apache已经设置支持SSI
那么就可以在指定的扩展名的文件中如同:
<!--#include file="../../include/top.html"-->
这样调用文件。你所说的我觉得应该是:
1. ../../include/top.html 找不到文件;
2. ../../include/top.html 如果路径没问题,那就是你的apache 已经设置吃.html也被当作.php 文件解释,并且top.html文件中有程序错误。
那么就可以在指定的扩展名的文件中如同:
<!--#include file="../../include/top.html"-->
这样调用文件。你所说的我觉得应该是:
1. ../../include/top.html 找不到文件;
2. ../../include/top.html 如果路径没问题,那就是你的apache 已经设置吃.html也被当作.php 文件解释,并且top.html文件中有程序错误。
apache并没有设置解析.html文件
<!--#include file="./include/top.html"-->
用<!--#include virtual="../../include/top.html" -->试试