让Nginx支持shtml格式

发现包括IIS在内的大多数处理服务器,都是默认不支持shtml的,nginx支持shtml的方法为:

在nginx.conf配置文件,添加:

ssi on;
ssi_silent_errors on;
ssi_types text/shtml;

然后保存,重启nginx即可。

This entry was posted in Nginx and tagged , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>