我在根文件夹中有一个带有htaccess的php站点。我在一个子文件夹中有一个博客,但由于博客htaccess与根文件夹中的htaccess冲突,所以wordpress博客没有加载。
这是两个htaccess文件
根文件夹
#Options +FollowSymLinks
Options -Multiviews
RewriteEngine on
#RewriteBase /lasercap/public_html/
RewriteCond %{REQUEST_URI} !^/blog/
#Map http://www.example.com/x to /jekyll/x unless there is a x in the web root.
#RewriteCond %{REQUEST_FILENAME} !-f
#RewriteCond %{REQUEST_FILENAME} !-d
#RewriteCond %{REQUEST_URI} !^/lasercap/public_html/
RewriteRule ^ISHRS2013$ ISHRS2013.php
RewriteRule ^(.*)$ /lasercap/public_html/$1
#DirectoryIndex /lasercap/public_html/site-offline.html index.html
DirectoryIndex /lasercap/public_html/index.php
用于Wordpress博客的htaccess
<Files .htaccess>
order allow,deny
deny from all
</Files>
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_URI} ^/blog/(.*)$ [OR]
RewriteCond %{REQUEST_URI} ^/failed_auth.html$
RewriteRule ^.*$ - [L]
</IfModule>
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /blog/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /blog/index.php [L]
</IfModule>
# END WordPress
任何人都可以帮助htaccess。我需要你的帮助。谢谢