I am trying to restrict access to a domain to one IP address, but allow anyone to access one directory within that domain. So I have this in my .htaccess (in web root):
<RequireAll>
Require ip xx.xx.xx.xx
</RequireAll>
which is working great to restrict access, but then when I want to allow unrestricted access to /folder within the root, so I tried:
<Directory "/home/*/public_html/folder">
Allow from All
Satisfy Any
</Directory>
but then I get a 500 error. So how would I accomplish this? And why the 500?
Also, for reference, here's the rest of the htaccess, which routes all requests to the index.php
# Remove ".php" from path
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^\.]+)$ $1.php [NC,L]
Options +FollowSymLinks
RewriteCond %{SCRIPT_FILENAME} !-f
RewriteCond %{SCRIPT_FILENAME} !-d
RewriteRule ^.*$ ./index.php
Thanks!