Creating Plug & Play Modules for OpenCms 8

From OpenCms Wiki
Revision as of 14:43, 29 July 2011 by Alkacon (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

About this tutorial

OpenCms, since its first public version, features a module mechanism that allows encapsulating functionalities in separate modules. However, the template mechanism of OpenCms up to version 7.5 left many details to the developer. It turned out that developing reusable modules is quite difficult, since there used to be many dependencies from a module to the template it was developed for. The improved template and module mechanism of OpenCms 8 addresses these issues, removes theses dependencies and therefore allows creating modules that are not depended on the template.

This tutorial includes an overview of the problem with pre-OpenCms 8 modules using the “Template 2” example from the OpenCms 7.x distribution. It shows how the problems have been addressed in OpenCms 8. Among other things, this includes the possibility to create HTML output that is rendered differently depending on the space available in the template.

Best practices for structuring modules are explained, for example how to layout module resources in different folders and naming conventions we suggest.

Download this tutorial

Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox