A
A
AlexMark2017-04-21 09:58:35
htaccess
AlexMark, 2017-04-21 09:58:35

How to redirect from a subdomain to another subdomain?

How to make a redirect from poddomen1.site.ru here poddomen2.site.ru and for all lower sections and pages?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
V
Viktor Taran, 2017-04-21
@AlexMark

A little strange question, the answer to which can be found on the Internet in 2 seconds
Maybe you need to clarify the question?

RewriteCond %{HTTP_HOST} ^(www\.|)poddomen1\.site\.ru [NC]
RewriteRule ^(.*)$ http://poddomen2.site.ru/$1 [R=301,L]

E
einbecker, 2020-05-14
@einbecker

if https

RewriteEngine On
RewriteCond %{HTTP_HOST} poddomen1.site.ru
RewriteRule (.*) https://poddomen2.site.ru/$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