服务器端包括 apache 启用
我正在尝试让 SSI 在我的网站中使用它。 我想做的第一件事就是启用它并进行回显以验证它是否有效。
我有 apache2,在根目录中有一个 SSI 文件夹,在该文件夹中我创建了一个 .htaccess 文件,如下所示:
Options +Includes
AddType text/html .shtml
AddOutputFilter INCLUDES .shtml
所以现在它应该启用 SSI。 (对吗?)
在SSI文件夹中有echo_ssi.shtml文件,包含:
<!--#echo var="DATE_GMT" -->
当我在浏览器中打开echo_ssi.shtml时,没有任何反应。 我想获取 GMT 时间和日期...
我在 SSI 启用配置中做错了什么? 我还需要做/添加其他事情吗?
I am trying to enable SSI to use it in my site.
The first thing that i am want to do is just enable it and do an echo to verified if it work at all.
I have apache2, in the root directory there is SSI folder and inside that folder i made a .htaccess file that look like this:
Options +Includes
AddType text/html .shtml
AddOutputFilter INCLUDES .shtml
So now its supposed to enable SSI. (right?)
in the SSI folder there is echo_ssi.shtml file, contain:
<!--#echo var="DATE_GMT" -->
when i am open echo_ssi.shtml in the browser, nothing happen.
I suppose to get time and date in GMT...
What im doing wrong in the SSI enable configuration?
There is somthing else that im need to do / add?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您是否扫描过 Apache 模块 mod_include 和 Apache SSI 教程文档?
您需要确保正在加载 mod_include。
如果您列出了
.htaccess
行,那么应该返回一个包含日期和日期的页面。时间。
Have you scanned the Apache Module mod_include and the Apache SSI Tutorial documentation?
You need to ensure that you are loading mod_include.
If you have then with the
.htaccess
lines that you list thenshould return a page with the date & time on it.
服务器现金出现问题。需要清理服务器上的现金。
There was a problem with the server cash. need to clean the cash on the server.