How to create and run a module from within the Admin Interface

In this tutorial we will show you how to create and execute a simple module. We'll also look at how we can:

  • Link resources to a module
  • Group module dependencies together

To view currently installed modules you need to go Manage modules screen. To load this screen click on either the Modules icon from the home page or on the Manage modules Menu link:

Clicking on one of the above will load the Manage modules screen:

The search bar on the right is used to search currently installed modules while the "New Modules" button on the left is user to create a new module.

We are now going to show you some basic steps in how you can create a simple phone book module.

To create a new module click on the "New module" button located on the search bar. In the module name field enter the name Phone book. You can also enter a description, an icon for the module.

Note: the Category and Resource fields are not activated in TP 3.

Note: The "Module disabled" checkbox is used to temporarily disable the module.

The field labeled "PHP" is where we will be adding our PHP code for the module but first let us have a look at the configuration tab.

The configuration tab is very similar to that used in snippets and plugins with the exception of the "GUID" and "Enable parameter sharing" properties.

The GUID (Globally Unique IDentifier) is use to uniquely identify the module and it's shared parameters within the system. This id is used to form a link between the module and the plugins or snippets accessing its shared parameters.

The Enable parameter sharing option is used to enable parameter sharing with other resources. When this option is enabled dependent snippets and plugins will be able to access to module's shared parameters.

In others the module can act as a data store for storing and sharing configuration parameters with snippets and plugins that are listed as module dependencies (more on this later).

In the above diagram Module A is sharing its configuration parameters with its dependent plugins and snippets. These plugins and snippets will automatically have Module A's configuration downloaded to them when they are executed.

So technically speaking any parameter that you set in Module A will be available to it's plugins and snippets as it was locally configured.

From the plugin or snippet configuration tab you would select the name of the module as follows:

Now that we understand shared parameters let's now take a look at how we can add configuration parameters.

Suggest an edit to this page.