简体   繁体   中英

Redirect non-www to www except subdomain

I have a wildcard domain. What I want are:

  • When user go to mydomain.com, it should be redirect to www.mydomain.com
  • When user go to subdomain.mydomain.com, keep the connect
  • When user go to www.subdomain.mydomain.com , it should be redirect to subdomain.mydomain.com

What I can do on domain configs (change the record types) or my web server (I'm using nginx)? I searching the questions but not solve my case. Thanks.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM