I’m using this .htaccess code to redirect the old domain to the new domain:
Options +FollowSymLinks
RewriteEngine on
RewriteCond %{HTTP_HOST} test.domain.eu(.*)
RewriteRule (.*) http://test.domain.be/$1 [R=301,L]
This works, also for subdirectories. But in the directory /project, there’s a Zend project with the following .htaccess:
SetEnv APPLICATION_ENV development
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} -s [OR]
RewriteCond %{REQUEST_FILENAME} -l [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.*$ - [NC,L]
RewriteRule ^.*$ index.php [NC,L]
When I go that directory on the old domain, the redirect doesn’t work. So I’m guessing these 2 .htaccess files conflict eachother. Does anyone have an idea how to make this work?
Add these 2 rules:
to
/project‘s .htaccess as well.Courtesy: @
TerryE.i.e.
/folder/folder1/folder2is the requested URI, and lets say all of them has.htaccessthen, folder2’s.htaccesswill only be used./folder/folder1/folder2is the requested URI, and lets say onlyfolder1has a.htaccessthen, folder1’s.htaccesswill only be used.So, do this: