Answer the question
In order to leave comments, you need to log in
How to redirect different domains to site.com/sitename?
I wonder how site builders redirect from the domain to their dynamic URLs for their local sites. for example I have 2 domains and I want to register ns of my site builder names so that they redirect to the correct urls generated by the site builder. let's say I have site1.com and site2.com and I want to redirect them to sitebuilder.com/site1 and sitebuilder.com/site2, how to solve it?
Answer the question
In order to leave comments, you need to log in
RewriteCond %{HTTP_HOST} ^(www\.|)(.+)\.site\.com [NC]
RewriteRule ^(.*)$ https://sitebuilder.com/%2/$1 [R=301,L]
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question