浏览代码

Update .htaccess

Visman 5 年之前
父节点
当前提交
9028d7f11a
共有 3 个文件被更改,包括 12 次插入3 次删除
  1. 6 0
      .dist.htaccess
  2. 0 3
      app/.htaccess
  3. 6 0
      public/.dist.htaccess

+ 6 - 0
.dist.htaccess

@@ -1,5 +1,9 @@
 AddDefaultCharset UTF-8
 
+<IfModule mod_autoindex.c>
+    Options -Indexes
+</IfModule>
+
 <IfModule mod_rewrite.c>
   RewriteEngine On
   #RewriteBase /
@@ -9,6 +13,8 @@ AddDefaultCharset UTF-8
 
   RewriteRule !^public/. index.php [L]
 
+  RewriteRule \.dist\. index.php [L]
+
   RewriteCond %{REQUEST_FILENAME} !-f
   RewriteRule ^public/ index.php [L]
 </IfModule>

+ 0 - 3
app/.htaccess

@@ -1,4 +1 @@
-<Limit GET POST PUT>
-Order Allow,Deny
 Deny from All
-</Limit>

+ 6 - 0
public/.dist.htaccess

@@ -1,9 +1,15 @@
 AddDefaultCharset UTF-8
 
+<IfModule mod_autoindex.c>
+    Options -Indexes
+</IfModule>
+
 <IfModule mod_rewrite.c>
   RewriteEngine On
   #RewriteBase /
 
+  RewriteRule \.dist\. index.php [L]
+
   RewriteCond %{REQUEST_FILENAME} !-f
   RewriteCond %{REQUEST_URI} !^/favicon\.ico$
   RewriteCond %{REQUEST_URI} !^/robots\.txt$