Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/wordpress/11.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Wordpress 排除htaccess中具有动态以下内容的特定url_Wordpress_Apache_.htaccess - Fatal编程技术网

Wordpress 排除htaccess中具有动态以下内容的特定url

Wordpress 排除htaccess中具有动态以下内容的特定url,wordpress,apache,.htaccess,Wordpress,Apache,.htaccess,我确实可以从wordpress安装中访问以下.htaccess # BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </I

我确实可以从wordpress安装中访问以下.htaccess

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

# END WordPress
#开始WordPress
重新启动发动机
重写基/
重写规则^index\.php$-[L]
重写cond%{REQUEST_FILENAME}-F
重写cond%{REQUEST_FILENAME}-D
重写规则/index.php[L]
#结束WordPress
我现在想排除一个特定的路径(wordpress不应该处理这个路径)。这适用于以下情况

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_URI} !^/foo$ [NC] #<-----------------
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

# END WordPress
#开始WordPress
重新启动发动机
重写基/
重写规则^index\.php$-[L]

重写cond%{REQUEST_URI}^/foo$[NC]#别担心,我发现了我的错误。我将把这个留给任何可能有同样“问题”的人。我在“foo”文件夹中有另一个.htaccess用于处理传入请求。而这个.htaccess有一个错误的基础。 是的

而且需要

RewriteBase /foo/
RewriteBase /foo/