V
V
Vitaly Kapranov2016-02-18 13:15:50
Joomla
Vitaly Kapranov, 2016-02-18 13:15:50

How to 302 redirect a website folder to a folder on a subdomain?

Greetings!
Faced the problem of 302 redirects, there is a bilingual site on Joomla, multilingually arranged with site.com/ru site.com/en folders. They decided to update the site, made a new one on WP, multilingualism was done the same way, the Russian version is ready, and over the English. I still need to work on the version, I want to upload a new site and English. move the version temporarily to a subdomain until a new one is ready.
Task: make a 302 redirect site.com/en/*(WP) to old.site.com/en/*(Joomla)

Answer the question

In order to leave comments, you need to log in

4 answer(s)
I
IceJOKER, 2016-02-18
@IceJOKER

Stop telling stories at last, ask a question right away, the rest is of no interest to anyone.

RewriteEngine on
RewriteCond %{HTTP_HOST} ^site.com$
RewriteRule ^en/(.*?) http://old.site.com/en/$1

A
alfik197, 2016-02-18
@alfik197

Redirect 302 site.com/en/*(WP) old.site.com/en/*(Joomla)

V
Vitaly Kapranov, 2016-02-18
@kfun

Decided by myself, it seems to work

RewriteEngine on
RewriteCond %{HTTP_HOST} ^site.com$
RewriteRule ^/en/[a-z,A-Z,0-9]/(.*)$ http://old.site.com/en/[a-z,A-Z,0-9]/(.*)$1 [R=301,L]

V
Viktor Taran, 2016-02-26
@shambler81

RewriteEngine on
RewriteCond %{HTTP_HOST} ^(www.|)site.com$
RewriteRule ^/en/.*/(.*)$ http://old.site.com/en/.*/(.*)$1 [R=301,L]

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question