只允许访问图片,限制其他,如php的访问
order allow,deny
deny from all
<Filesmatch "\.(jpg|gif|jpeg|png)$">
Order allow,deny
allow from all
</Filesmatch>
方法二:关闭apache php的解析
<Files *>
php_flag engine off
</Files>
只允许访问图片,限制其他,如php的访问
order allow,deny
deny from all
<Filesmatch "\.(jpg|gif|jpeg|png)$">
Order allow,deny
allow from all
</Filesmatch>
<Files *>
php_flag engine off
</Files>