Can anyone help me with this rewrite rule?
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !^.*\.html$ [NC]
RewriteCond %{REQUEST_FILENAME} !^.*\.htm$ [NC]
RewriteCond %{REQUEST_FILENAME} !^.*\.jpg$ [NC]
RewriteCond %{REQUEST_FILENAME} !^.*\.jpeg$ [NC]
RewriteCond %{REQUEST_FILENAME} !^.*\.gif$ [NC]
RewriteCond %{REQUEST_FILENAME} !^.*\.png$ [NC]
RewriteCond %{REQUEST_FILENAME} !^.*\.swf$ [NC]
RewriteRule ^.*$ - [F]
This works fine, except when you try to get a directory index without specifying a filename. So I tried adding:
RewriteCond %{REQUEST_FILENAME} !^$ [NC]
as part of the rule, but to no avail -- I still get a forbidden on directory indexes unless I specify the filename.
__________________
SIG TOO BIG! Maximum 120x60 button and no more than 3 text lines of DEFAULT SIZE and COLOR. Unless your sig is for a GFY top banner sponsor, then you may use a 624x80 instead of a 120x60.
|