Multisite - Multiple TLD

I have been working to setup a new multisite network and I have run into a challenge that I can't seem to find the solution for on the forums/support. I have the multisite installed on a primary TLD - working great. I added a few secondary TLD's - but can't seem to figure out how to activate them. I CAN add subdomains to the secondary TLD's and they work great, but I can't seem to get WP to show up on the actual TLD.

primary.tld - works perfect
secondary.tld - doesn't work
sub.secondary.tld - works perfect

I have read several posts that talk about this, but it seems that once they find the solution they don't update the post or the final solution is very specific to their setup.

Some details:

This is on a development site - that isn't visible to the public. I have the latest WP version and all themes and plugins are updated.

I can provide more details - but thought I would start with a few basic questions:

1. Can you point me to any guides or posts that explain how to setup multiple TLD's on a single multisite? Specifically with regards to the WP install on the TLD's - as I can get subdomains set up on them without issue.

2. If there aren't any guides or posts - which WPMU plugins do I need to have installed to get a basic setup like this working? I understand I can add other plugins to add functionality like ProSites to monetize this setup - but I really just want to get the basic setup first on my development site and then go from there.

3. If you have any suggestions or Best Practices you can share - Great! They would be appreciated.

If you have any questions you need answered please let me know and I will provide all information requested.

Thanks for any help you can provide!

-Scott

  • Sajid

    Hello Scott Michaud,
    Hope you are doing good today :slight_smile:

    First of all please make sure all your mapped, non primary TLDs are resolving on the same IP where you have WordPress MultiSites install and all other TLDs document root path is set to the same folder (most cases public_html).

    For more information please read the following blog article that explains how to map a domain using our Domain Mapping plugin.
    https://premium.wpmudev.org/blog/wordpress-multisite-masterclass-domain-mapping/

    Please note that, the most critical part while mapping the domain is configuring the domain correctly on your hosting. Once it is configured the way it is explained then the rest is easy peazy. So please pay close attention on how to point the domain, IP address and document roots etc..

    Hope that helps! Feel free to post a reply if you need further assistance :slight_smile:

    Best Regards,
    Sajid - WPMU DEV Support

  • Scott Michaud

    Hi Sajid - Sorry for my delayed response.

    I am going around in circles right now - so let me ask a few specific questions that I either missed in the documentation or are not covered (or my brain has glazed over).

    Also - sorry for the long email. Because I am not sure where I am missing a step - I tried to give you as much information as possible.

    I have a VPS. On the VPS I have a primary IP address - which is considered "Shared". But for all intensive purposes it is dedicated to the sites which will be on the network. Does this IP meet the requirements?

    I also have a Dedicated IP address purchased. So if the above doesn't work I can change 'back' to this IP. I have tried them both - but again, between all the troubleshooting and time for IP's to propagate - I could be missing things.

    All the domains on my VPS will be part of the Multisite Network. As of now they are all on the Primary (shared) IP address.

    So the first question - which IP should I use? The Primary or the Dedicated?

    Parked Domain or A Record? Based on the documentation, support forums and the VPS Support team - I am pretty confused on the next step. I was told by VPS Support to put the Network Domain on a Dedicated IP and then Park all the secondary domains. I tried this and it didn't work. Again, I could be missing a small step in this process - but I have now made changes 4 or 5 times and am getting a bit turned around.

    Setup/Goals Reminder:

    I am setting up a Multisite Network on http://www.primarydomain.com - this domain is on my VPS and presently pointed at the Primary (shared) IP address. I also have several secondary domains on the VPS and presently pointed at the Primary (shared) IP address. For this example, I will use the below.

    Primary IP Address: 184.168.999.99
    Dedicated IP Address: 94.178.999.99

    Network Primary Domain: http://primarydomain.com
    Secondary Domain 01: http://secondarydomain01.com
    Secondary Domain 02: http://secondarydomain02.com

    Subdomain Primary Domain: http://support.primarydomain.com
    Subdomain Secondary Domain 01: http://client01.secondarydomain01.com
    Subdomain Secondary Domain 02: http://client03.secondarydomain02.com

    Note: Both Secondary Domains are basically business specific vertical community sites. I have considered putting each on their own Multisite Network Install - but, from what I read - because about 85% of the sites will share core functionality it could work all on a single install. I am open to suggestions here - but for now, my goal is to build them all on one network. Keep in mind - the defining factor that ties all the community sites together is a Lead Generation Program we provide our clients. So the primary difference from community to community will be in the Themes and a small number of vertical specific Plugins - which I should be able to control with WPMUdev Plugins.

    The Primary Domain for this example will be my agency domain. It will have a front end website advertising/promoting my company. The Primary Domain will also have several "Sub Domains" to support different features - for example, a Support Site (http://support.primarydomain.com).

    The Secondary Domains are business vertical communities. So the main URL for the community (http://secondarydomain01.com) will be the website advertising and promoting the community. The Subdomains will be specific client sites (http://client01.secondarydomain01.com) who are part of the community.

    Hope all this makes sense. I have it all mapped out - it is just a matter of getting the setup correctly. And like I said, I have gone around in circles on this.

    IF, I move the Primary Domain to the Dedicated IP Address:

    Primary IP: 184.168.999.99

    WordPress Installation Setup
    WordPress Multisite Setup
    Installed Domain Mapping Plugin and Setup

    Note: Made changes to wp-config, added sunrise.php, etc.

    At this point everything appeared to be working.

    Network Admin: I can see the Domain Mapping Plugin in the Network Plugins under Settings.

    Primary Website Admin: Based on the documentation, it appears that I should see the Domain Mapping Plugin in the Website Admin under Tools. Correct?

    I am worried that all my problems after this might be due to this issue - but again, I could be totally wrong.

    Using the example above - the next step would be adding the Secondary Domains - correct? Can you give me an example of the A Record settings? Because whenever I get to this step I must be messing something up.

    A Record for http://secondarydomain.com: Doing this from the cPanel Simple Zone Editor for the domain http://secondarydomain.com.
    - Name: ??
    - Address: ??

    Reminder: Please remember, that during this process I was able to get the network setup and add subdomains from the Secondary Domains. Meaning - I setup the network, add a domain name and then was able to add a subdomain. The problem was that I couldn't see the Secondary Domain - only the Subdomain of the Secondary Domain.

    http://secondarydomain.com - didn't show website or admin.
    http://client01.secondarydomain.com - worked perfectly.

    I am not sure how this worked - how did the subdomain work? I mention this because it added to my confusion.

    With ALL that said, please let me know if you need other information. I am really trying to avoid blowing up everything and starting over. But if I can't get it resolved soon - I will go down that route. My fear, is that it will be the same outcome.

    Thanks again!

    -Scott

  • Sajid

    Hello Scott Michaud,
    Hope you are doing good and welcome back :slight_smile:

    Please accept my sincere apologies for confusion. I thought you are trying to use Domain Mapping on WordPress MultiSites. Where as you need to use this on WordPress Multi Network, most probably with this plugin:
    https://wordpress.org/plugins/wp-multi-network/

    Please note that, Domain Mapping plugin is designed to be used on WordPress MultiSites only.

    I have not tried Domain Mapping plugin myself on such setup so not exactly sure whether it should work or not.

    For such conversation, we have members area forum from where you may get help from other experienced members running a similar setup. So, I advice you post in Web Development and Coding members only forum for some insights.

    Take care and have a nice day :slight_smile:

    Best Regards,
    Sajid - WPMU DEV Support

  • Scott Michaud

    Sajid - Thanks for the response. This is the first time I have heard this - I had communicated this setup before I every purchased WPMUdev and was told I could accomplish what I needed. Bit frustrating, because based on the responses I have wasted weeks of time trying to troubleshoot the issue - Reading those Guides over and over again. With that said, I get it - and will explore the forum board you recommended.

    However, I would like to take a step back. While the above was the setup I envisioned based on previous conversations - I am not trying to create something so complex I run into more issues. So lets pretend I just want a single network.

    Question: Based on the Masterclass you referenced previously - Client Sites & Domain Mapping. Can you explain exactly what is going on behind the directions in the guide? Basically what I am looking for is to understand is what is the specific relationship Client Sites have with the Network they are added.

    Again for this example:
    Network Domain --> http://maindomain.com
    Client Domain --> http://clientdomain.com

    When the Client Domain is added to the Network Domain - does it have to point to a Subdomain or is it a standalone domain on the Network?

    For example:
    If I created --> http://clientdomain.maindomain.com

    I ask this because in the Guide - it discusses Primary vs Secondary Domains - this section makes it sound like "Secondary" Domains only point to the "Primary" Domain. My assumption is that the Secondary Domain would be my Client Domain the the Primary Domain would be my Network Domain - but the exact relationship and how it actually works isn't really explained in the Guide. Can you shed some light on this?

    It gets a bit more fuzzy when I then continue to read the Guide and get to the section called: Pointing a Domain at Your Network. Can you give me an example of an A Record and/or CNAME? Remember, I have a VPS from GoDaddy. So I have access to WHM for the VPS and cPanel for each domain on the VPS. I have stopped "assuming" I know what should be added - mine could be correct, but because it isn't working I am not sure where the issue is. So by giving me an example of what information should go in the "Name" and "Address" fields in the Simple Zone Editor would at least allow me to feel more comfortable with the step as I troubleshoot.

    Continuing down the Guide - assuming I got the A Record and/or CNAME correct I moved on to the section: Adding Domains to a Site. In this section it discusses going to Tools --> Domain Mapping. However, I don't see that option in my main site (http://maindomain.com) - I do however see that option in the subdomain (http://clientsite.maindomain.com). So this takes me back to the above question about understanding what the relationship of the Client Site is to my Network. Make sense?

    It appears that I have to create a Subdomain of my Network Domain and then in the Admin Section of the newly created Subdomain I can then "Map" the Client Domain to the Subdomain. Is that correct? I have done this and can't seem to get it working - again, if my A Record and/or CNAME are incorrect then this step obviously wouldn't work, but if I have them right - what could be my issue?

    So that is where I am at. The Guides are good - but they lack some specific examples to take any "user errors" out of the equation. They also aren't totally clear (at least to me) what is exactly going on behind this setup.

    How exactly does a Client Domain interact with the Network Domain?

    Once I understand this I can make other decisions and troubleshoot in different directions.

    Other things that could be impacting this setup:

    IP Address: Details are above - but to summarize. I am on a VPS. I have all my domains on this VPS. There is a Primary IP Address shared by all these domains. I do have the ability to put the Network Domain on its own Dedicated IP Address if needed. Realize I have tried all the above steps with a Dedicated IP Address and it didn't work - but because I am unsure about previous steps I am not sure if this has an impact on things. So which direction should I go?

    IF, I have to use the Dedicated IP Address - how should I then point the Secondary Domains to the Network Domains? I have read information with many different ways to do it - Park Domains/A Record/CNAME/Alias/etc - I have tried them all. Pretty frustrated. So based on your above recommendations - Can you give me a practical example of this step?

    Also, does the Multi-Domain Plugin have any place in this setup?

    Hope I have provided you enough information to help - please let me know if you have any questions. Please respond as soon as you can - as I am trying to get this foundation setup so I can move on to getting these things launched. Time is money :slight_smile:

    Thanks Again.

  • Sajid

    Hello Scott Michaud,
    Hope you are doing good :slight_smile:

    I am sorry for confusion and frustration. As I said above it is not officially supported by some member has make it work with MultiNetwork. But this is obviously a complex setup and require some level of technical knowledge related to IP, domains and DNS management.

    For MultiSites, you can definitely use this plugin for mapping subsites with top level domain.

    When the Client Domain is added to the Network Domain - does it have to point to a Subdomain or is it a standalone domain on the Network?

    So here is the process.

    1. You need to enable WordPress MultiSites (if not enabled).

    2. Create a subsite from Network Dashboard -> Sites -> Add New.

    3. Now you have to configure the domain on your server, either using A record or CNAME (please forget the primary and secondary domains at the moment - we just going to map one domain at the moment).

    Please find more details about how to point your domain on your server here by following instructions mentioned in "DNS: A and CNAME Records" section of this blog or as described in "A Record & CNAME" section of Usage Guide.

    Also, please note that you don't need to create a subdomain for this Domain on your server.

    But in some cases, you may need to add it as an add-on domain in cPanel and set its document root to public_html (the same folder where you have installed WordPress MultiSites).

    4. Once you have configured it on your server now its time to add map with your subsite. Log in to your subsite dashboard as administrator. Go to Subsite Dashboard -> Tools -> Domain Mapping and enter the domain in Map new domain name: field to map it.

    I do however see that option in the subdomain (http://clientsite.maindomain.com). So this takes me back to the above question about understanding what the relationship of the Client Site is to my Network. Make sense?

    Yes that is where you should be mapping the domain with that specific subdomain/subsite.

    There is no direct relationship of mapped domain or client site with Network/Main domain. It has indirectly though, so mapped domain -> subdomain -> network/primary domain.

    IF, I have to use the Dedicated IP Address - how should I then point the Secondary Domains to the Network Domains? I have read information with many different ways to do it - Park Domains/A Record/CNAME/Alias/etc - I have tried them all. Pretty frustrated. So based on your above recommendations - Can you give me a practical example of this step?

    In this case, I recommend you using the dedicated IP address for domain mapping. For an example of setup please see below screenshot:

    Also, please send in cPanel details, the domain you are mapping, the subdomain/subsite link and WordPress admin details so I could also take a look at the setup using our secure contact form in following format.

    You can send the requested details via our secure contact form in following format.

    Subject: "Attn: Sajid Javed”
    - WordPress admin username
    - WordPress admin password
    - login url
    - domain to be mapped.
    - subdomain where this need to be mapped.
    - cPanel credentials (link/username/password)
    - link back to this thread for reference

    Also, does the Multi-Domain Plugin have any place in this setup?

    For this setup, I don't think you need Multi-Domain plugin. You can just stick with the Domain Mapping plugin at the moment.

    Take care and have a nice day :slight_smile:

    Best Regards,
    Sajid - WPMU DEV Support

  • Scott Michaud

    Sajid - Thanks for your reply. I was able to get my multisite up and running. My biggest challenge - as you know - was my setup wasn't exactly "standard". And with that, the testing/troublshooting process when dealing with server changes (IP, DNS, etc) can be slow and painful. With that said, while it isn't exactly what I originally envision - it is working and I can move forward. So thanks for your patience and assistance.

    I do have one final question:

    Once setup I have an issue with the URL structure (www vs http vs just TLD). With a normal WP setup I understand the settings and have never had an issue.

    However, when I went to map the new domains - the plugin would give me an error if I just used - http://domain.com. If I used http://www.domain.com it would map it.

    That then leads to the problem if I go into my browser and type either http://domain.com or just domain.com - I am taken to a page that that shows "Index of/" and then lists cgi-bin and wp-config.php. If I type http://www.domain.com or http://www.domain.com the site works as intended.

    Where do I fix this? Do I need to set another A Record? Or is it a fix in a WP file?

    Thanks again!

  • Sajid

    Hello Scott Michaud,
    Hope you are doing good today :slight_smile:

    I am glad to know you have figured out the domain mapping for standard WordPress MultiSites setup.

    For second issue, HTTP or non HTTP is not an issue because even if you type the domain.com in browser it end up being http://domain.com. So nothing need to do here.

    For non-www to www, you can setup a redirect rule by using the following code in .htaccess file. This will redirect all non-www requests to www.

    Add following code in .htaccess file right after the RewriteEngine On and of course replace yourdomain.com with your own domain name.

    RewriteCond %{HTTP_HOST} ^yourdomain.com [NC]
    RewriteRule ^(.*)$ http://www.yourdomain.com/$1 [L,R=301]

    Hope that helps! Feel free to post a reply if you need further assistance :slight_smile:

    Best Regards,
    Sajid - WPMU DEV Support

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.