Hi all, Im new to Webfaction and would like to use the FilesMatch Directive through htaccess to reject any requests for files with names that include a particular string. I have the following in my htaccess file however the files are still being served.
Does any one have any idea why it is refusing to work, or how to get it to work correctly. Can something be done via php.ini? I would be very grateful for any help. Thanks. asked 22 Dec '11, 04:54 Rick22 |
Your FilesMatch directive should work. Can you verify that you are not using a "Static only (no .htaccess)" kind of application, as those are being served from our frontend nginx webserver where htaccess files are not getting interpreted? Also, check for any typos in your regular expression, or even in the filename of your htacess file. answered 22 Dec '11, 05:28 iliasr ♦♦ I'm using a Static/CGI/PHP application. The documentation says that htaccess should work with this type, I have checked the expressions however still no luck. When I purposely insert an mistake error 500 comes up so i think the file is being read ok, All i have done with this app is set a document root and php.ini, along with some scripts that work fine. Could i have messed up configuration somehow? any other ideas on what I could do to figure out a solution? thanks.
(22 Dec '11, 06:12)
Rick22
Hi, The most likely reason is that your regular expression does not match the files correctly. If you open a ticket, we can take a look at it for you.
(22 Dec '11, 06:23)
todork
Yep, Regex did not match correctly. Thanks all.
(22 Dec '11, 09:03)
Rick22
|