How to make a parametric redirect from one subdomain to another?

0 like 0 dislike
Good day!
There is a need to do a redirect from one subdomain to another (transferring materials).
Is there an url and
1. should be moved to the root of the second subdomain
Understand that enough rules
Redirect 301 /2019/01/

2. contains a particular post, which is on the second subdomain, but with CNC the kind of
Tell me, how to do a redirect for the second case?

P. S. was thinking about
RewriteRule ^(.*)/ /2019/01/post.html?m=0 /(.*)$ $1/ /$2 [R=301,L]
but it didn't.
by | 124 views

1 Answer

0 like 0 dislike
Redirect 301 /2019/01/ RewriteRule ^(.*)/ /2019/01/post.html?m=0 /(.*)$ $1/ /$2 [R=301,L]

RewriteEngine On RewriteRule ^2019/01/$ [R=301,L] RewriteCond %{QUERY_STRING} =m=0 RewriteRule ^2019/01/post\\.html$ [R=301,L]
110,608 questions
257,187 answers
40,796 users