I think you are making an assumption that I know what I'm doing
And vice versa ;) But see boilerplate in some adjoining thread about "Why We Make You Do It Yourself".*
I've kinda lost track, but I
think this was where we left off:
RewriteCond %{THE_REQUEST} /\w+\.(php|html)
RewriteRule ^(([^/.]+/)([^/.]+/)+)[^/.]+\.(php|html) http://www.example.com/$1 [R=301,L]
Meaning: If the user asks for any named file in a subdirectory, send 'em to the same subdirectory's index file. This includes explicit requests for the index.php file by name-- which is handy, because normally that would be a separate mopping-up redirect near the end of your rewrites.
The line looking at THE_REQUEST is necessary because a bit later on, mod_dir will come along and silently rewrite
directory/
to
directory/index.php
You don't want to go around in circles and you don't want the address bar to say "index.php". (If you know SEO you already know that part. A directory's name officially ends in a slash. If you allow the alternative /index.xtn you've got the dreaded Duplicate Content.)
* Except for the Title Case in that phrase. I do that with a keyboard shortcut. Heh.