I have a client who operates a large (50+ sites) multisite/network installation of WordPress. When this network was first set up, the only solution available to map domains to sites in the network was the WordPress MU Domain Mapping plugin, so that's what they've been using for many years now. It's kind of clunky, but it works.

As of WP 4.5, however, domain mapping has been included natively in WordPress core. The WordPress MU Domain Mapping plugin, as a consequence, has pretty much been abandoned. For this reason, I would like to migrate this network from the plugin-based mapping to the built-in mapping.

However, documentation on how to actually do this is spotty at best. The closest thing to an official guide is this pinned thread from the plugin's support forum. It only addresses what I would consider the simplest migration case, however, which is the case where every site in the network has one and only one domain mapped to it. That's not our case, though; the Domain Mapping plugin allowed you to map multiple domains to a single site in a network, so we have sites with half a dozen domains mapped to them. I have yet to find any documentation on how migrating works in that case.

What steps are required to migrate from the Domain Mapping plugin to the built-in domain mapping support, in cases where individual sites in the network may have multiple mapped domains?

有帮助吗?

解决方案

Has anyone out there migrated a non-trivial network installation of WP from the plugin to native domain mapping? If so, could you share the steps you took to make it happen, with particular emphasis on how you dealt with sites that had multiple domains mapped?

You can't.

Mapping multiple domains to a single blog/site is not a use case handled by WP core. The canonical answer for mapping multiple domains to a single blog is still to install a plugin such as domain mapping or Mercator.

WP supports native domain mapping, not domain mappings. You can change the home and site urls to a different domain, but you cannot have multiple home and multiple site urls without a plugin.

许可以下: CC-BY-SA归因
scroll top