I took over the web site of a company where the previous developer had put in a rewrite rule in the .htaccess that looks like this:

RewriteEngine on
RewriteRule .* index.php [L]

So, now whenever we try to use a .html file, it rewrites it to a .php file. However, this is really only needed for the main web site which is OsCommerce based. When I try to view the stats directory, I get a 404 error because all the files in there are .html and not .php.

I would like to set this up so that it does not apply to the 'stats' directory which is created by webalizer and builds .html file.

How can I change this rule to not apply to the '/stats' directory off of the root of the web site?