Download the PHP package plasticstudio/modulemanager without Composer
On this page you can find all versions of the php package plasticstudio/modulemanager. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download plasticstudio/modulemanager
More information about plasticstudio/modulemanager
Files in plasticstudio/modulemanager
Package modulemanager
Short Description Module Manager for SilverStripe - forked from jaedb/modulemanager
License BSD-3-Clause
Homepage http://plasticstudio.co.nz/
Informations about the package modulemanager
Module Manager
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
- 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
composer require plasticstudio/ModuleManager
- Run /dev/build?flush=1
- Setup your Module Positions. There is an initial
after_content
area setup to get you started. - Insert your Module Positions in your template (ie
$ModuleArea(after_content)
)
Usage
Create a module area
-
Edit your
app/_config/config.yml
file to add any additional module areas. Use the following format: - In your template, use the code
$ModulePosition(ALIAS)
where ALIAS is your position's alias string. - Run dev/build (
/dev/build?flush=all
)
Create a module instance
- Within the Module Manager admin, create a new
Module
object. The type dropdown will show the list of available module types. - Assign your new
Module
object to one of the positions you configured inconfig.yml
.
Build a custom module type
-
Create a new DataObject file
app/src/Modules/MyModule.php
: -
Create your template file
app/templates/{NameSpace}}/MyModule.ss
: - Perform a build and flush (
/dev/build?flush=all
) - Now you can create your custom module type
Modules inheritance
To avoid having to set a module on each page within a section, you can set your pages to inherit it's parent page's modules.
- Open your page, and navigate to the Modules tab
- Check Inherit Modules and Save your page.
- You can apply this inheritance further up the page hierarchy if required.
All versions of modulemanager with dependencies
silverstripe/framework Version ^4 || ^5
silverstripe/vendor-plugin Version ^2