.htaccess has no effect on Apache
Hi. I'm trying to get a custom 404 to work on Apache. I have done the following:
1) I made a plain text document called .htaccess and put it into the root of my web accessable directory ( /var/www/htdocs on my slackware box ). The .htaccess document contains the following line
I then made the special 404 file and put it into /var/www/htdocs/errors/ After I did that, in my browser typed in a non-existent file-name in my domain into the location bar, I still got the regular default apache 404:
ErrorDocument 404 /errors/404.html
2) I then read some more docs and learned that I need to tell httpd.conf to allow .htaccess to override its settings, which I did by making sure this was in my httpd.conf file:
The requested URL /3213 was not found on this server.
Apache/1.3.31 Server at ruby.cerealport.com Port 80
It still didn't work when I tested it in the browser.
3) I asked a couple friends for help, we tried taking out the leading slash in the .htaccess file's relative URL, and that didn't work. We changed the note in httpd.conf to "AllowOverride All" and that didn't do anything. We tried a couple other oddball long-shot things that didn't work either.
4) I read this:
I did what it suggested and found nothing.
.htaccess file doesn't seem to change anything
It's possible that the directory is within the scope of an AllowOverride None directive. Try putting a line of gibberish in the .htaccess file and force a reload of the page. If you still get the same page instead of an 'Internal Server Error' display, then this is probably the cause of the problem. Another slight possibility is that the document you're requesting isn't actually controlled by the .htaccess file you're editing; this can sometimes happen if you're accessing a document with a common name, such as index.html. If there's any chance of this, try changing the actual document and requesting it again to make sure you can see the change. this isn't happening.
Just to let you know, the webpage for the special 404 does work. You can see it at http://www.cerealport.com/errors/404.html
I have no idea why this isn't working. I'm pretty frustrated by this. If anybody has any tips or pointers they would be very appreciated.