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


lucy24 - 11:00 pm on Nov 21, 2012 (gmt 0)


Add an extra RewriteCond condition in the ruleset that internally rewrites.
This will test that REQUEST_URI is NOT ^/customerrors/

Isn't it too late then? A custom 404 page can only be (internally) requested if the server has previously returned a 404, and the all-purpose

RewriteRule . /index.php [L]

prevents that from happening in the first place. Besides, the error page does exist, so no rewrite would happen.

You can do one or the other-- use a custom error page OR send everything to index.php-- but it's hard to do both.

And what if someone requests a nonexistent image? Shouldn't the boilerplate at least be constrained to php and/or no extension? (Yes, I realize that isn't specific to the current question. It's built in. But it still seems like overkill.)


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