ErrorDocument 404只显示“404”

I have setted up my .htaccess with some bundles of rewrites, although when I go to an invalid directory which the ErrorDocument 404 is already set up, it just shows "404" on the page, nothing else, just a plain text with "404".

RewriteEngine on

RewriteBase /
RewriteRule ^404/?$ 404.php

ErrorDocument 404 404

Why doesn't it show the 404 page, if I go to 404.php or http://www.mydomain.com/404 it shows just fine, why won't it show the page?

You need to reformat your .htaccess, see: http://www.javascriptkit.com/howto/htaccess2.shtml

The correct line is:

ErrorDocument 404 /errors/notfound.html