我在Windows Server 2008 R2 Enterprise上運行Apache 2.4(64位)和PHP 5.4.15,並且注意到Apache錯誤日誌中有以下錯誤:Apache 2.4 - 由於可能的配置錯誤,請求超過了10個內部重定向的限制
AH00124: 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.
我有一個多站點安裝的WordPress運行,我認爲錯誤來自htaccess重寫錯誤。
看這個帖子: Request exceeded the limit of 10 internal redirects due to probable configuration error.?
他們建議,以取代這樣的:有這一段代碼,斯科特楊禮貌
# BEGIN Wordpress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.+)$ /index.php/$1 [L,QSA]
</IfModule>
然而,我的WordPress htaccess看起來有點不同,所以我不只是想替換我的代碼,以防萬一我無意中替換了我需要的東西。
這裏是我的htaccess:
# BEGIN WordPress
<IfModule mod_rewrite.c>
Options +FollowSymLinks -MultiViews
Header set Access-Control-Allow-Origin "*"
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>
# END WordPress
任何人都可以提出什麼,我需要改變嗎?
謝謝,anubhava解決這一點。我會給出一個去,並儘快報告:) – iltdev
我不害怕。它仍然記錄在日誌中的錯誤:( – iltdev
註釋掉'RewriteRule ^(wp-(content | admin | includes)。*)$ 1 [L]'也是。 – anubhava