问题描述
location /data/attachment/ { location ~ .*.(php)?${deny all; }}
搜了半天给的例子都是这样的每个目录都复制一遍的就太那啥了吧...
问题解答
回答1:location ~ (/data/attachment/|/xxoo/|/ooxx/oxox) { location ~ .*.(php)?${deny all; }}
正则啊

问题描述
location /data/attachment/ { location ~ .*.(php)?${deny all; }}
搜了半天给的例子都是这样的每个目录都复制一遍的就太那啥了吧...
问题解答
回答1:location ~ (/data/attachment/|/xxoo/|/ooxx/oxox) { location ~ .*.(php)?${deny all; }}
正则啊
相关文章:1. linux - gcc 和 gcc-c++ 啥区别2. apache - 如何在 .htaccess 设置规则阻止下载 .htaccess 文件3. CentOS 6.5怎么安装PHP-FPM?4. centos - greenplum安装问题5. macos - mac上同怎样时使用抓包工具charles和mamp的Apache?6. centos postfix7. nginx - capistrano 在部署项目时出现"sorry, you must have a tty to run sudo“怎么处理呢?8. nginx - 关于服务器搭建问题9. linux - SSH连接到服务器,一段时间不操作后会卡住,是怎么回事呢?10. 为什么把git管理的文件夹从Windows下直接手动复制到Linux会发生变化?

网公网安备:皖ICP备2020019022号-8 Copyright ¢ 2020-2025 Powered by V1.8 All Rights Reserved 技术支持:乐呵呵网
声明:本站所有资源以学习为主