Reputation: 11
I am using WP multisite with domain mapping and I have noticed in my logs that I get "Request exceeded the limit of 10 internal redirects due to probable configuration error. Use 'LimitInternalRecursion' to increase the limit if necessary. Use 'LogLevel debug' to get a backtrace."
My .htaccess is:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
# add a trailing slash to /wp-admin
RewriteRule ^wp-admin$ wp-admin/ [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^(wp-(content|admin|includes).*) $1 [L]
RewriteRule ^(.*\.php)$ $1 [L]
RewriteRule . index.php [L]
</IfModule>
I have tried commenting out:
RewriteRule ^(wp-(content|admin|includes).*) $1 [L]
RewriteRule ^(.*\.php)$ $1 [L]
As well as changing
RewriteRule ^(..php)$ $1 [L] to RewriteRule ^(..php)$ - [L]
but that results in 500 errors.
I am running Apache/2.2.22 (Debian) Server. I know very little about .htaccess and apache I am afraid.
Upvotes: 1
Views: 656
Reputation: 9308
This should do the same thing but more simply, and, hopefully without recursion:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
# add a trailing slash to /wp-admin
RewriteRule ^wp-admin$ wp-admin/ [NS,R=301,L]
# redirect everything that isn't a file…
RewriteCond %{REQUEST_FILENAME} !-f
# and isn't a directory…
RewriteCond %{REQUEST_FILENAME} !-d
# and isn't in the special wp directories…
RewriteCond $0 !^wp-(?:content|admin|includes)(?:$|/)
# and isn't already the index file…
RewriteCond $0 !=index.php
# and isn't the empty string to the index
RewriteRule .+ index.php [NS,L,DPI]
</IfModule>
Upvotes: 0