Luca Reghellin
Luca Reghellin

Reputation: 8113

Why Apache's <Files> directive keeps giving me error 500?

This directive in .htaccess:

<Files wp-config.php>  
order allow,deny  
deny from all 
</Files>

Gives me error 500. Ave you maybe got some good idea about?

Thank you

Upvotes: 0

Views: 307

Answers (1)

cdhowie
cdhowie

Reputation: 169183

Two possibilities jump to mind:

First, usually I see the filename quoted: <Files "wp-config.php">. I forget whether Apache requires quotes or not, so try this and see if that fixes the problem.

Second, your Apache server administrator may not have enabled the required AllowOverride permissions to allow you to do this.

In either case, checking the Apache error logs will reveal the true problem.

Upvotes: 1

Related Questions