Actions

Difference between revisions of "How do you create a custom module?"

From Joomla! Documentation

m (clean up categories with <noinclude> tags)
 
(2 intermediate revisions by 2 users not shown)
Line 81: Line 81:
 
As a Super Administrator, you can restrict the Access Level to Special, and then only you (and the other admins!) will see a module when you are logged in on the front of the site.
 
As a Super Administrator, you can restrict the Access Level to Special, and then only you (and the other admins!) will see a module when you are logged in on the front of the site.
  
[[Category:FAQ]]
+
<noinclude>[[Category:FAQ]]
 
[[Category:Administration FAQ]]
 
[[Category:Administration FAQ]]
 
[[Category:Getting Started FAQ]]
 
[[Category:Getting Started FAQ]]
 
[[Category:Version 1.5 FAQ]]
 
[[Category:Version 1.5 FAQ]]
[[Category:Module Management]]
+
[[Category:Module Management]]</noinclude>

Latest revision as of 15:34, 1 September 2012

Quick Overview: To make a custom module, go to Extensions, then Module Manager and click on the New icon. You'll see a list of available modules. Click on Custom HTML and begin editing the module.

Detail: A module is a special program, or even a special type of article, that can be displayed in the Module Positions available in your joomla website's template.

To see all of your template's available module positions, add the code

?tp=1

after one of your pages URLs

eg. http://www.yoursite.com.au/?tp=1

To see the list of all the modules on your site:

In the administrator site, go to Extensions > Module Manager

Before you create a new one, look at an example:

Login Form

- it is of a particular type mod_login

Title - the title of this module

Show Title - no or yes if you want the title displayed

Position - this relates to your available Module Positions referred to above

Order - the order the module is displayed if there is more than one module in its position (you control this after SAVING the module and looking at all the modules for this position - see Order of the Modules for a position, below).


Menu Assignment

This is where you choose when this module will be displayed.

All, None, Selected Menu Item(s)

For the example Login Form, the Module will only display when the user is in the Home menu.


Module Parameter

Some modules have Parameters associated with them that are set from this screen.


Create your new 'Custom Module'

To display some information on some or all pages, in say the left column (a very common module position), you can go to the Module Manager and create a NEW custom module.

In Module Manager - hit the New button, and choose Custom Html

Choose a title, whether to show it, enable your module, select a position, assign menus, then fill in your Custom Output in the edit screen below the Menu Assignment.


Parameters

Note that Module Class Suffix is a setting that will relate to the Template you are using - it may not be set. Refer to the template's documentation to use this parameter.


Try it out

Put in a test module and see what you can achieve. Set Enabled to "No" to turn it off if you are not ready to display it to the world.


Order of the Modules for a position

In the Module Manager, restrict which modules you are looking at by choosing the position from the drop down menu - Select Position -

You can now use the green arrows to move Modules up or down, or re-number the modules and click on the small save icon (between Order and Access Level) to save your new order.


Access Level

You use this to control who can see a module.

For example, the User Menu has a red Registered as its access level - this means that this Module is only seen when a registered user is logged in.

As a Super Administrator, you can restrict the Access Level to Special, and then only you (and the other admins!) will see a module when you are logged in on the front of the site.