Is it possible to apply different rewrite rules for different IP addresses using only one .htaccess file?
I have these rules:
RewriteEngine on #RewriteCond %{REMOTE_ADDR} !^123\.456\.789\.123 RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d #RewriteRule ^(.*)$ /version/1.0/index.php?r=$1 [L] RewriteRule ^(.*)$ /version/2.0/index.php?r=$1 [L]
Both of the last two rules work fine, and I can choose which one to enable. I want to somehow include one rule for myself to work on the development version, and another rule for production.
Is there any way to use IP filtering for this? Is it even possible? Is there another alternative solution so that I can include both rules: one for development and the other for production?
source share