How can we achive a 403 Permissions Denied for a subdomain?

Posted by marikamitsos on Server Fault See other posts from Server Fault or by marikamitsos
Published on 2012-07-06T20:20:04Z Indexed on 2012/07/07 3:17 UTC
Read the original article Hit count: 410

Filed under:
|

We have a multisite installed in the root directory (multisite.com) and also a wordpress single installation on a subdomain (help.multisite.com)

In the root .htaccess we placed:

#START Security: Disallow access to folders
Options All -Indexes
# END Security

On the main site (as expected we get)

"403 Permission Denied. You do not have permission for this request /wp-content/blogs.dir/83/"

Nice. :)

BUT. We just noticed that when trying to access the subdomains folders we get:

Internal Server Error. The server encountered an internal error or misconfiguration and was unable to complete your request.... Additionally, a 500 Internal Server Error error...

This is something we do NOT want.

So the question is:

How can we avoid the above result and make the message for the subdomains be "403 Permission Denied" (the same as for the main site and NOT "500 Internal Server Error" (as it is now)? We put what, where?

© Server Fault or respective owner

Related posts about .htaccess

Related posts about subdomains