There are 2 inbuilt Joomla plugins to load modules into content. These in-built plugins cannot load modules by their ID so you will need to use a 3rd party extension for that. There are some great 3rd party plugins that will also allow you to insert modules into content but by the module ID if you want.
[loadmodule] and [loadposition] Plugins
Unless you know how to use these powerful features or even the syntax you will find them very difficult to use. There usage is slighty different but the syntax is very similiar so if you can use one you can use the other. With both the plugins don't forget you will need to enable it in the Plugin manager. If you want a module to appear you must make sure that it is published. You also need to make sure the module is visible on the pages you want in its menu tab, or you can restrict it.
[loadmodule]
This plugin allows you insert modules into content by specifying the module group ( ie custom / custom_html / login / mod_login ). I have not check which variations od the module group names work and where to get them from. If there is more than 1 module published in that group they will all be publish, so if you only want 1 module to be embedded you need to specify the title of the module. You can specify a module by it's name even if there is only 1 module in that group, it does not ahrm. The last switch is for styling and i am not sure exactly how to use it.
Syntax [loadmodule moduletype,title,style] Examples [loadmodule custom] - This will load all of the 'Custom HTML' modules that are published [loadmodule custom,My Code] - This will load the 'Custom HTML' module titled 'My Code' NB: Swap [] for {} - I used brackets instead of curly braces so Joomla did not parse the demo text.
[loadposition]
This plugin will load all modules from the specified position one after the other.
The way to use this to get a specific module to display in your content is to create your module and assign it to a custom module position. To put a module in a custom position, when you edit the module rather than using the drop down menu to select a position you can just type your own in (i.e. myposition) and then save the module.
Syntax [loadposition position,style] Examples [loadposition right] - This will load all modules in the right module position. [loadposition myposition] - This will load all modules in the custom module position called 'myposition'. NB: Swap [] for {} - I used brackets instead of curly braces so Joomla did not parse the demo text.
Getting the Module's Type
- You can get the module's type from the module list in joomla. This only gives you an indication of the modules name
i.e. BT Google Maps - You then get the modules required name from your website via ftp. Browse to /modules/ and in there you will see the modules name which should be similiar to the name above. In some circumstances the names might not be similiar.
i.e. mod_bt_googlemaps
3rd Party Extensions
- Modules Anywhere - Joomla! Extension Directory - Can insert modules by their ID/Name/Position and other options. there is a free and paid version
- SLOMO - Joomla! Extension Directory - The SLOMO plugin is based on the original loadmodule content plugin, however, it has been improved and new features have been added. SLOMO is a complete replacement for the original loadmodule plugin, you can safely disable it and use SLOMO instead.
- Load module into article - Joomla! Extension Directory - I have not used this but the usage is simple.
- Module Plant - Joomla! Extension Directory - Joomla! system plugin that shows any Joomla! module in any content. With this plugin you can override some module parameters or create virtual instance of a module which does not require saving module parameters in a database.
Links
- How do you put a module inside an article? - Joomla! Documentation - This gives some brief notes about these Plugins and covers all the syntax
- Joomla! • View topic - is not working with custom html module - A forum thread that makes you understand how to use {loadmodule} and the extra options.
- {loadposition} and {loadmodule} in Joomla Articles | OSTraining - A good article but does not cover the extended syntax
- Embedding a Module into an Article (Joomla 2.5) | Cloudaccess - A good clean article but does not cover the extended syntax
- Using the Joomla LoadModule Plugin | Joomla Tips | How-To - A good article theat mentions the extended syntax to specify the module you want by title.
- Using the Joomla Load Module Plugin – Eddify.me - A slideshow covering all feature of {loadmodule}