.htaccess problem


# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
ErrorDocument 401 /home/happyjumper/jumper.com/errors/401/
ErrorDocument 403 /home/happyjumper/jumper.com/errors/403/
ErrorDocument 404 /home/happyjumper/jumper.com/errors/404/
ErrorDocument 500 /home/happyjumper/jumper.com/errors/500/
ErrorDocument 503 /home/happyjumper/jumper.com/errors/503/
# END WordPress

This is how my .htaccess is laid out. If you try to access http://happyjumper.com/testest you will get redirected to another page that is part of the theme itself. Not the correct redirect (which should be like a clock) can someone help me debug why this is happening?



Yes, all WordPress themes are required to include a 404.php page.

Your “ErrorDocument” should be something like this:

ErrorDocument 400 /errors/400.php
ErrorDocument 401 /errors/401.php
ErrorDocument 403 /errors/403.php
ErrorDocument 404 /errors/404.php

You should also try putting them outside the WordPress code. WordPress has its own way of handling 404 errors, however, so you should read this:


jumper.com is not a valid site, so you’ll want to fix that.


Hmmm I have it pretty much like that, except the error pages are more elegant and SEO friendly… I still don’t know why mine won’t launch from the site, if they are added and directed in the .htaccess

The only difference of the .htaccess account you sent in and mine is that mine is pointing to a directory, (where a .html launches the error response) and yours is pointing to a .php… so does it need to be 404.php ? why wouldn’t it work just with http://happyjumper.com/errors/404/ ?

this is just the name of a directory, the actual domain is happyjumper.com


Probably because ‘jumper.com’ is not a valid site. This link:


Does not resolve to a valid web site. (Try it yourself.) There is nothing there.

This link works:


However, WordPress prefers to handle these errors internally, if it can. Read this article to find out how to do that and what to put in your .htaccess file:

I don’t know about that. They have a completely different appearance to the main site, so any visitor who comes upon them and isn’t web-savvy (i.e., 97.5% of your visitors) probably won’t realize what they are looking at and will experience a minor freak-out. You always have to view design issues from a user’s point of view, not your own.
This page is older, but also has good information:

(However, its method of creating a child theme is entirely out of date. We no longer use the “@import” method.)


ErrorDocument must point to a file that “physically” exists on the disk. You can’t use it to point to a virtual path created by rewrite rules. (Those only exist with respect to URLs anyway, not to filesystem paths.)