PHPackages                             trendwerk/domains - 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. trendwerk/domains

AbandonedArchivedWordpress-muplugin[Utility &amp; Helpers](/categories/utility)

trendwerk/domains
=================

Domains for WordPress Multisite.

0.2.0(9y ago)247.0k1GPL-2.0+PHPPHP &gt;=5.4

Since May 12Pushed 9y ago4 watchersCompare

[ Source](https://github.com/trendwerk/domains)[ Packagist](https://packagist.org/packages/trendwerk/domains)[ RSS](/packages/trendwerk-domains/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (3)Dependencies (2)Versions (4)Used By (0)

Domains
=======

[](#domains)

Domains for WordPress Multisite.

Requires WordPress 4.5+. Specifically meant for using domains on *subdirectory* Multisite installs.

*Note: This plugin **does not** replace all existing URLs in the database. Therefore, it is recommended to install this immediately after creating a multisite install.*

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

[](#installation)

If you're using Composer to manage WordPress, add this plugin to your project's dependencies. Run:

```
composer require trendwerk/domains
```

Setup
-----

[](#setup)

The basic setup of this plugin consists of two steps:

1. [Define the correct constants](#constants) in your WordPress configuration file (default: `wp-config.php`)
2. [Configure the `.domains` file](#configuration), which is the main configuration file for this plugin

### Constants

[](#constants)

```
define('SUNRISE', true);
```

This activates a WordPress drop-in plugin called `sunrise.php`. Allows this plugin to perform actions right before Multisite is loaded.

```
define('CONTENT_DIR', '/app');
```

This is only necessary if your content folder is not located in the default `/wp-content` folder. The example above uses `/app`.

```
define('DOMAIN_CURRENT_SITE', 'www.example.com');
```

Probably not necessary to say, but this should be defined when using Multisite. This plugin relies on it being defined as well.

#### Omit these constants

[](#omit-these-constants)

Never define the following constants when using Multisite and this plugin:

- `WP_CONTENT_URL` - should be defined by this plugin
- `WP_HOME` - not used by Multisite
- `WP_SITEURL` - not used by Multisite

### Configuration

[](#configuration)

The `.domains` file is the main configuration file for this plugin and contains all domains. It is set up in the format `blogId:domain`. Domain aliases can be created by separating domains by a comma. For example:

```
2=www.example.com,example.com
3=www.example.org

```

The domains file should be located in the root of your project. This file should probably be excluded from version control, since enviroments are usually run on different domains. When using [Capistrano](http://capistranorb.com/) for deployment, it should be defined as a linked file.

*Note: This plugin searches for the `.domains` file in the folder where WordPress is located and a maximum of two folders up.*

###  Health Score

31

—

LowBetter than 68% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity31

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~112 days

Total

3

Last Release

3433d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/3ce3274dfde64e7afdd8a1c06a861dd0e65267afaba097fda8bad934877a471f?d=identicon)[haroldangenent](/maintainers/haroldangenent)

---

Top Contributors

[![haroldangenent](https://avatars.githubusercontent.com/u/1481468?v=4)](https://github.com/haroldangenent "haroldangenent (47 commits)")

###  Code Quality

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/trendwerk-domains/health.svg)

```
[![Health](https://phpackages.com/badges/trendwerk-domains/health.svg)](https://phpackages.com/packages/trendwerk-domains)
```

###  Alternatives

[rainlab/blog-plugin

Blog plugin for October CMS

17257.7k](/packages/rainlab-blog-plugin)[rainlab/builder-plugin

Builder plugin for October CMS

17147.2k1](/packages/rainlab-builder-plugin)[pfefferle/wordpress-activitypub

The ActivityPub protocol is a decentralized social networking protocol based upon the ActivityStreams 2.0 data format.

5671.4k1](/packages/pfefferle-wordpress-activitypub)[civicrm/civicrm-drupal-8

Open source constituent relationship management for non-profits, NGOs and advocacy organizations.

18238.1k2](/packages/civicrm-civicrm-drupal-8)[mediawiki/semantic-glossary

A terminology markup extension with a Semantic MediaWiki back-end

1352.4k](/packages/mediawiki-semantic-glossary)[humanmade/lottie-lite

A lightweight Lottie Animations Extension for WordPress

374.3k](/packages/humanmade-lottie-lite)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
