I want to redirect domainA.com/folder/ which originates from an older WordPress installtion (not Enfold) to domainB.com/folder1/folder2/ (Enfold within WordPress Network) which is the link to the page within my new wordpress installation wihtout the url changing.
I have managed to achieve this with the .htaccess file inside domainA.com/folder/ which reads:
RewriteEngine On
RewriteCond %{REQUEST_URI} ^/folder
RewriteRule ^(.*)$ http://www.domainB.com/folder1/folder2/ [P]
The Rewriterule [P] (proxy) flag does what I want and redirects the page without changing the url but some of the content within my Enfold WP template such as the advanced layer slider and icons fail to load.
I assume this error is due to some sort of conflict with WP’s native htaccess code and I also suspect it has to do with the lines:
RewriteBase /
RewriteRule ^index\.php$ – [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
I have experimented with adding the first, third and fourth lines to my code but it doesnt work. Does anybody know how I could resolve this issue?
If it makes any difference the wordpress site I want to direct to (domainB.com/folder1/folder2/) is one whithin a WordPress Network.
For the moment I have changed the [P] flag to [L] flag which redirects and works but changes the url.
Any help or advice would be much appreciated. Thank you!
Hey TelemedicineClinic!
I’m not sure anyone in support would be able to help with this but I will tag the others in case anyone might have some ideas.
Cheers!
Devin