PHPackages                             nowzoo/wp-domain-map - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. nowzoo/wp-domain-map

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

nowzoo/wp-domain-map
====================

Simplified domain mapping for WordPress Networks

v0.2(11y ago)023MITPHP

Since Apr 6Pushed 11y agoCompare

[ Source](https://github.com/nowzoo/wp-domain-map)[ Packagist](https://packagist.org/packages/nowzoo/wp-domain-map)[ Docs](https://github.com/nowzoo/wp-domain-map)[ RSS](/packages/nowzoo-wp-domain-map/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (1)Versions (3)Used By (0)

NowZoo WordPress Domain Mapping
===============================

[](#nowzoo-wordpress-domain-mapping)

Simplified domain mapping for WordPress networks, installed via Composer.

This package is meant for WordPress installations already using Composer. If you need a "normal" WordPress plugin, that you can install without Composer, you might try [MU Domain Mapping](https://wordpress.org/plugins/wordpress-mu-domain-mapping/). We might turn this into a plugin at some point.

Why?
----

[](#why)

I got frustrated with MU Domain Mapping -- it's too complicated for the purposes of a small network.

Some advantages of this code:

- Custom domain information is stored in one site option.
- The `home` and `siteurl` options for each blog are ignored and not changed.
- Works well with a mix of subdomain sites and sites with custom domains.
- It's independent of DNS. You don't have to tell it IP addresses or CNAMEs.

Installation
------------

[](#installation)

```
$ composer require nowzoo/wp-domain-map

```

After installation, copy `sunrise.php` (included in the package root directory) to the `wp-content` directory.

Instantiate the admin panel by including this code somewhere (e.g in `wp-content/mu-plugins/index.php`):

```
