Forum Moderators: phranque

Message Too Old, No Replies

404 error acting weird

         

gms3651

3:08 pm on Oct 6, 2006 (gmt 0)

10+ Year Member



Hello,
My website is having some issues when it comes to displaying the 404 Error page. I have a directory as [mydomain.com...] We'll if I type [mydomain.com...] That page that's located at 'http://www.mydomain.com/about/me.htm' will pop up. The page will pop up whenever I use the filename (me.htm) as a directory name (me/a/b/c/junk.htm). This same behavior is going on in every directory of my site.

Does anybody have any suggestions?

Thank You

jdMorgan

3:58 pm on Oct 6, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Check to see if content-negotiation is turned on. If it is, and if you don't use it, then turn it off. This can be done using

Options -MultiViews

in your top-level .htaccess file.

If content-negotiation is enabled, and the server can't find a requested resource, it will try to find a 'best-fit' match on the requested URL, and serve whatever it finds. So, that may be happening here.

Another possibility is that your 404 ErrorDocument directive is incorrect.

It should look like this:


ErrorDocument 404 /path-to-404-error-page.html

Note that leading slash, and that no protocol or domain name is prepended -- both are critical factors. See the ErrorDocument documentation for details.

Jim