Answer the question
In order to leave comments, you need to log in
How to change htaccess?
Good afternoon, here is an example of how redirection from a subdomain to a folder of the main domain is going on
RewriteEngine on
RewriteBase /
#адрес поддомена
RewriteCond %{HTTP_HOST} ^(www\.)?sub\.domain\.dev$ [NC]
#папка на которую будет происходить переадресация
RewriteCond %{REQUEST_URI} !^/sub/
#сама переадресация
RewriteRule ^(.*)$ sub/$1 [L]
Answer the question
In order to leave comments, you need to log in
1. htaccess supports nesting and can be located in any folder, so it will override the higher one.
2. you do not need to redirect, use the regular
DocumentRoot of the sub site. should lead to the /var/www/domain.dev/sub folder (well, or whatever it is for you)
Well, if your admin panel does not allow you to change this path and you are afraid of using your hands.
THEN just make a link . (this is a type of shortcut) supported by the file system itself
1 command.
If it’s completely scrapped, then mc has a graphical version.
Link and enjoy.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question