darrellblackhawk
Programmer
Hello,
I have an .htaccess file that I'm using as a the base of router on a client site.
As you can see, it will route all requests for non-existent files to: index.php.
What I'd like to add in addition, is the ability to restrict access to specific sub-directories in the directory that this .htaccess file is located in.
Also, I'd like to allow certain IP's to allow a select set of files in these restricted sub-directories.
Thanks much in advance.
I have an .htaccess file that I'm using as a the base of router on a client site.
Code:
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} -s [OR]
RewriteCond %{REQUEST_FILENAME} -l [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.*$ - [NC,L]
RewriteRule ^.*$ index.php [NC,L]
As you can see, it will route all requests for non-existent files to: index.php.
What I'd like to add in addition, is the ability to restrict access to specific sub-directories in the directory that this .htaccess file is located in.
Also, I'd like to allow certain IP's to allow a select set of files in these restricted sub-directories.
Thanks much in advance.