Support » Networking WordPress » Can the main site of a multisite be a subdomain?

  • tintomatoes

    (@tintomatoes)


    I have a slightly complicated scenario.

    Here is what I want to do:
    http://www.mydomain.com – Instance A of wordpress, not a multisite
    abc.mydomain.com – Instance B of wordpress, not a multisite
    def.mydomain.com – Instance C of wordpress, multisite, main site
    ghi.mydomain.com – Instance C of wordpress, multisite, one of the sites
    jkl.mydomain.com – Instance C of wordpress, multisite, one of the sites
    mno.mydomain.com – Instance C of wordpress, multisite, one of the sites
    etcetera…

    Is this possible?

    My developer told me it is not possible. He said that the main site of a network must be the root domain itself – therefore in my scenario Instance C would have to replace Instance A. Also, he said that activating wildcard subdomains would break any independent WordPress installations on subdomains i.e. Instance B. Is he correct on both counts?

    Can anyone suggest any workaround?

    The reason I can’t touch Instance A or Instance B is because they are managed by other people in our organisation who do not want their sites to be part of my multisite Instance C. But we all want to be on the same domain.

Viewing 7 replies - 1 through 7 (of 7 total)
  • jkhongusc

    (@jkhongusc)

    > He said that the main site of a network must be the root domain itself – therefore in my scenario Instance C would have to replace Instance A

    This is incorrect. Our http://www.domain.com is attached to another web server (not WP). We have our WP multisite main site attached to wordpress.domain.com; and we use WP domain mapping tool to mapped our WP sub-sites to: site1.domain.com, site2.domain.com, etc. The latest WP handles this natively without using a plugin. Note we have to (manually) add the (subsite) cnames to our wordpress.domain.com DNS entry.

    > Also, he said that activating wildcard subdomains would break any independent WordPress installations on subdomains i.e. Instance B.

    I dont understand this statement, must be something lost in translation =) But your scenario above is possible, it depends on your host… how much control they allow you to configure on DNS. Example DNS configuration:
    http://www.mydomain.com A 1.1.1.1
    abc.mydomain.com A 1.1.1.2
    *.mydomain.com CNAME wordpress.mydomain.com

    http://www.mydomain.com will go to whatever IP address that server is located (in this example 1.1.1.1). Same for abc.mydomain.com, goes to 1.1.1.2. All other traffic *.mydomain.com will go to your wordpress instance.

    tintomatoes

    (@tintomatoes)

    Thanks jkhongusc.

    Good to know that the main site can be on a sub-domain.

    >> Also, he said that activating wildcard subdomains would break any independent WordPress installations on subdomains i.e. Instance B.
    > I dont understand this statement, must be something lost in translation =)

    What I meant is that in my scenario abc.mydomain.com is not part of the multisite, it is a separate wordpress installation. So, by activating wildcard sub-domains at the server level, will it cause any problem for abc.mydomain.com?

    jkhongusc

    (@jkhongusc)

    > What I meant is that in my scenario abc.mydomain.com is not part of the multisite, it is a separate wordpress installation. So, by activating wildcard sub-domains at the server level, will it cause any problem for abc.mydomain.com?

    Yes, this can be done. Ive given an example of how to do it via DNS when the web servers for http://www.mydomain.com and abc.mydomain.com are on separate servers. This can be done even if all the domains are routed (via DNS) to the same server(s), in Apache httpd you would create VirtualHosts for each domain.

    Sorry reactivate this topic but still on top of it would be possible to be in sites network subdomain for example app.mywebsite.com (primary network) and to create a new site he’s created in newwebsite.mywebsite.com? And no, newwebsite.app.mywebsite.com

    Ex: https://ecohospedagem.lojaintegrada.com.br/ (is client site) and https://app.lojaintegrada.com.br/painel/login is a control panel

    My example above do not use wordpress, but is just to understand the logic …

    @andersonnarciso

    Yes you can achieve that. You can have:

    Main site: mainsite.mywebsite.com
    Sub-site: subsite.mywebsite.com – this would be mapped from subsite.mainsite.mywebsite.com, but you don’t need to worry because it is masked and no visitor will ever see this long URL. The mapping is handled in the multi-site network settings.

    We achieved this with wildcard sub-domains.

    My understanding is that sub-sites of a network are natively one level up from the main site, but with mapping you can effectively mask that and ‘demote’ it back it to the same level.

    Man @tintomatoes, and it’s not that it worked hahaha! The bad news is that every time you have a new site I’m going to have to manually map site.main.domain.com to site.domain.com or is there a way to automatically map?

    Sorry, I don’t know.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Can the main site of a multisite be a subdomain?’ is closed to new replies.