PHPackages                             plasticstudio/modulemanager - 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. plasticstudio/modulemanager

ActiveSilverstripe-vendormodule[Utility &amp; Helpers](/categories/utility)

plasticstudio/modulemanager
===========================

Module Manager for SilverStripe - forked from jaedb/modulemanager

6.0.0(3mo ago)02.4kBSD-3-ClausePHP

Since Aug 20Pushed 2mo agoCompare

[ Source](https://github.com/PlasticStudio/ModuleManager)[ Packagist](https://packagist.org/packages/plasticstudio/modulemanager)[ Docs](http://plasticstudio.co.nz/)[ RSS](/packages/plasticstudio-modulemanager/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (6)Dependencies (6)Versions (29)Used By (0)

Module Manager
==============

[](#module-manager)

Description
-----------

[](#description)

Manage site-wide modules (aka widgets) and select the pages on which they are to appear. This allows you to repurpose content across your website, and build easily modular content elements.

Dependencies
------------

[](#dependencies)

- SilverStripe 4

For a Silverstripe CMS 4.x compatible version of this module, please see the 3.x or 4.x release line.

- Release 4.x uses new namespace (plasticstudio\\ModuleManager)
- Release 3.x uses legacy namespace (Jaedb\\ModuleManager)

For a Silverstripe CMS 3.x compatible version of this module, please see the 3 branch, or 2.x release line.

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

[](#installation)

1. `composer require plasticstudio/ModuleManager`
2. Run /dev/build?flush=1
3. Setup your Module Positions. There is an initial `after_content` area setup to get you started.
4. Insert your Module Positions in your template (ie `$ModuleArea(after_content)`)

Usage
-----

[](#usage)

### Create a module area

[](#create-a-module-area)

1. Edit your `app/_config/config.yml` file to add any additional module areas. Use the following format:

```
PlasticStudio\ModuleManager\ModuleManager:
  positions:
    {ALIAS}: "{NAME}"

```

2. In your template, use the code `$ModulePosition(ALIAS)` where ALIAS is your position's alias string.
3. Run dev/build (`/dev/build?flush=all`)

### Create a module instance

[](#create-a-module-instance)

1. Within the *Module Manager* admin, create a new `Module` object. The *type* dropdown will show the list of available module types.
2. Assign your new `Module` object to one of the positions you configured in `config.yml`.

### Build a custom module type

[](#build-a-custom-module-type)

1. Create a new DataObject file `app/src/Modules/MyModule.php`:

```
