禁用PHP目录(包括所有子目录)用的.htaccess [英] Disable PHP in directory (including all sub-directories) with .htaccess
本文介绍了禁用PHP目录(包括所有子目录)用的.htaccess的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在做一个网站,使人们可以上传文件,HTML页面,等等...现在我有一个问题。我有一个这样的目录结构:
I'm making a website which allows people to upload files, html pages, etc... Now I'm having a problem. I have a directory structure like this:
-/USERS
-/DEMO1
-/DEMO2
-/DEMO3
-/etc... (every user has his own direcory here)
-index.php
-control_panel.php
-.htaccess
现在我想禁用PHP,但启用服务器端包含在里面/用户direcories和子目录
Now I want to disable PHP, but enable Server-side includes in the direcories and subdirectories inside /USERS
可以这样做(如何:))?先谢谢了。
Can this be done (and how :) )? Thanks in advance.
顺便说一句,我使用WAMP服务器
BTW, I use WAMP server
推荐答案
尝试禁用的 引擎
选项在你的.htaccess文件:
Try to disable the engine
option in your .htaccess file:
php_flag engine off
这篇关于禁用PHP目录(包括所有子目录)用的.htaccess的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文