.htaccess - Redirect all accessible URL's to only one specific subdomain -


i have working worpress domains, subdomain , alias working , locate @ root web server "www/".

htpps://domain.com htpps://domain.net htpps://en.domain.net 

later decide install support web application in same server in folder "www/support/".

setting support app needed set 1 domain or subdomain, , set "support.domain.com".

after last step realise following url's access support app:

htpps://domain.com/support htpps://domain.net/support htpps://en.domain.net/support  htpps://support.domain.com/support htpps://support.domain.net/support 

since support app doesn't work correctly differents domains or subdomains main 1 set ( was: "support.domain.com" ), i'm trying redirect 1 unique subdomain: "support.domain.com".

the file ".htaccess" locate in support app folder ("www/support/.htaccess") still empty, rewrite rules try didn't worked, due low knowledge.

  • how redirect accessible url's 1 "support.domain.com"?

or

  • block access folder "www/support/index.php" not "support.domain.com"?

i found , try lots of similar questions none work correctly or give many redirections.

in support.htaccess, can use following rule

rewriteengine on rewritecond %{request_filename} -f rewritecond %{request_filename} -d rewriterule ^.+ http://support.domain.com/ [l] 

Comments

Popular posts from this blog

magento2 - Magento 2 admin grid add filter to collection -

Android volley - avoid multiple requests of the same kind to the server? -

Combining PHP Registration and Login into one class with multiple functions in one PHP file -