Page is a not externally linkable
- Code, Content, and Presentation
-- Apache Web Server
---- index.php redirect breaking 404 pages.


Sgt_Kickaxe - 2:16 am on Dec 9, 2012 (gmt 0)


I'm encountering some odd behavior in wordpress when the following is placed above the index.php and www to non-www code. Ideas?

RedirectMatch permanent ^/some-old-url$ http://www.example.com/some-new-url

What happens is that http://example.com/index.php/some-old-url first redirects to http://www.example.com/some-old-url and then goes to http://www.example.com/some-new-url. Since the redirect matched shouldn't it go right to http://www.example.com/some-new-url?

The standard wordpress entry is further down the page and seems to be redirecting first...
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]


edit: RedirectMatch is used instead of Redirect due to host limitations


Thread source:: http://www.webmasterworld.com/apache/4520914.htm
Brought to you by WebmasterWorld: http://www.webmasterworld.com