开发者

using htaccess to restrict access on root when subdomains are also present

开发者 https://www.devze.com 2023-02-10 21:30 出处:网络
Consider the following structure: example.com locates to public_html/index.php example2.com locates to public_html/SUB/e2/index.php

Consider the following structure:

example.com locates to public_html/index.php

example2.com locates to public_html/SUB/e2/index.php

I want to take example.com down for maintenance, and thought htaccess would be the best method. But then I became worried that doing so would block access to the secon开发者_运维百科d (unrelated) site, because to the server it is located within the first site.

Would an htaccess-driven block at example.com also kill off example2.com ?


Isnt there a thing like "priority" in htaccess files?

I mean e.g. you first block the access to "public_html"

and then allow access to "public_html/SUB/e2" etc. ?

Must work i think.

0

精彩评论

暂无评论...
验证码 换一张
取 消