Plugin/Events/Module: Difference between revisions
From Joomla! Documentation
Tagged/Marked for translation |
Marked this version for translation |
||
| Line 1: | Line 1: | ||
<noinclude><languages /></noinclude> | <noinclude><languages /></noinclude> | ||
<translate>In a standard installation of Joomla! we have several predefined Module events which, when triggered, call functions in the associated plugins.</translate> | <translate><!--T:1--> | ||
In a standard installation of Joomla! we have several predefined Module events which, when triggered, call functions in the associated plugins.</translate> | |||
==onRenderModule== | ==onRenderModule== | ||
<translate> | <translate> | ||
===Description=== | ===Description=== <!--T:2--> | ||
</translate> | </translate> | ||
<translate>This is an event that is called when a module on the front- or back-end is rendered.</translate> | <translate><!--T:3--> | ||
This is an event that is called when a module on the front- or back-end is rendered.</translate> | |||
<translate> | <translate> | ||
===Parameters=== | ===Parameters=== <!--T:4--> | ||
</translate> | </translate> | ||
*<code>&module</code> <translate>A reference to a Module object that holds all the data of the module</translate> | *<code>&module</code> <translate><!--T:5--> | ||
*<code>&attribs</code> <translate>An array of attributes for the module</translate> | A reference to a Module object that holds all the data of the module</translate> | ||
*<code>&attribs</code> <translate><!--T:6--> | |||
An array of attributes for the module</translate> | |||
<translate> | <translate> | ||
===Return Value=== | ===Return Value=== <!--T:7--> | ||
</translate> | </translate> | ||
<translate>None. Result will be omitted.</translate> | <translate><!--T:8--> | ||
None. Result will be omitted.</translate> | |||
==onAfterRenderModule== | ==onAfterRenderModule== | ||
<translate> | <translate> | ||
===Description=== | ===Description=== <!--T:9--> | ||
</translate> | </translate> | ||
<translate>This is an event that is called when after a module is rendered on the back- or front-end</translate> | <translate><!--T:10--> | ||
This is an event that is called when after a module is rendered on the back- or front-end</translate> | |||
<translate> | <translate> | ||
===Parameters=== | ===Parameters=== <!--T:11--> | ||
</translate> | </translate> | ||
*<code>&module</code> <translate>A reference to a Module object that holds all the data of the module</translate> | *<code>&module</code> <translate><!--T:12--> | ||
*<code>&attribs</code> <translate>An array of attributes for the module</translate> | A reference to a Module object that holds all the data of the module</translate> | ||
*<code>&attribs</code> <translate><!--T:13--> | |||
An array of attributes for the module</translate> | |||
<translate> | <translate> | ||
===Return Value=== | ===Return Value=== <!--T:14--> | ||
</translate> | </translate> | ||
<translate>None. Result will be omitted.</translate> | <translate><!--T:15--> | ||
None. Result will be omitted.</translate> | |||
==onPrepareModuleList== | ==onPrepareModuleList== | ||
<translate> | <translate> | ||
===Description=== | ===Description=== <!--T:16--> | ||
</translate> | </translate> | ||
<translate>This is an even that is called before the list of modules that must be rendered is created. If the <code>&modules</code> parameter is an array of module objects, the default module list generated by Joomla! is ignored.</translate> | <translate><!--T:17--> | ||
This is an even that is called before the list of modules that must be rendered is created. If the <code>&modules</code> parameter is an array of module objects, the default module list generated by Joomla! is ignored.</translate> | |||
<translate> | <translate> | ||
===Parameters=== | ===Parameters=== <!--T:18--> | ||
</translate> | </translate> | ||
<translate>*<code>&modules</code> Reference to a empty variable for the list of modules</translate> | <translate><!--T:19--> | ||
*<code>&modules</code> Reference to a empty variable for the list of modules</translate> | |||
<translate> | <translate> | ||
===Return Value=== | ===Return Value=== <!--T:20--> | ||
</translate> | </translate> | ||
<translate>None. Result will be omitted.</translate> | <translate><!--T:21--> | ||
None. Result will be omitted.</translate> | |||
==onAfterModuleList== | ==onAfterModuleList== | ||
<translate> | <translate> | ||
===Description=== | ===Description=== <!--T:22--> | ||
</translate> | </translate> | ||
<translate>This is an even that is called after the list of modules that must be rendered is created.</translate> | <translate><!--T:23--> | ||
This is an even that is called after the list of modules that must be rendered is created.</translate> | |||
<translate> | <translate> | ||
===Parameters=== | ===Parameters=== <!--T:24--> | ||
</translate> | </translate> | ||
*<code>&modules</code> <translate>Reference to an array of module objects</translate> | *<code>&modules</code> <translate><!--T:25--> | ||
Reference to an array of module objects</translate> | |||
<translate> | <translate> | ||
===Return Value=== | ===Return Value=== <!--T:26--> | ||
</translate> | </translate> | ||
<translate>None. Result will be omitted.</translate> | <translate><!--T:27--> | ||
None. Result will be omitted.</translate> | |||
==onAfterCleanModuleList== | ==onAfterCleanModuleList== | ||
<translate> | <translate> | ||
===Description=== | ===Description=== <!--T:28--> | ||
</translate> | </translate> | ||
<translate>This is an event that is called after the module list is cleaned.</translate> | <translate><!--T:29--> | ||
This is an event that is called after the module list is cleaned.</translate> | |||
<translate> | <translate> | ||
===Parameters=== | ===Parameters=== <!--T:30--> | ||
</translate> | </translate> | ||
*<code>&modules</code> <translate>A reference to an array of rendered module objects</translate> | *<code>&modules</code> <translate><!--T:31--> | ||
A reference to an array of rendered module objects</translate> | |||
<translate> | <translate> | ||
===Return Value=== | ===Return Value=== <!--T:32--> | ||
</translate> | </translate> | ||
<translate>None. Result will be omitted.</translate> | <translate><!--T:33--> | ||
None. Result will be omitted.</translate> | |||
Revision as of 18:03, 16 June 2016
In a standard installation of Joomla! we have several predefined Module events which, when triggered, call functions in the associated plugins.
onRenderModule
Description
This is an event that is called when a module on the front- or back-end is rendered.
Parameters
&moduleA reference to a Module object that holds all the data of the module&attribsAn array of attributes for the module
Return Value
None. Result will be omitted.
onAfterRenderModule
Description
This is an event that is called when after a module is rendered on the back- or front-end
Parameters
&moduleA reference to a Module object that holds all the data of the module&attribsAn array of attributes for the module
Return Value
None. Result will be omitted.
onPrepareModuleList
Description
This is an even that is called before the list of modules that must be rendered is created. If the &modules parameter is an array of module objects, the default module list generated by Joomla! is ignored.
Parameters
&modulesReference to a empty variable for the list of modules
Return Value
None. Result will be omitted.
onAfterModuleList
Description
This is an even that is called after the list of modules that must be rendered is created.
Parameters
&modulesReference to an array of module objects
Return Value
None. Result will be omitted.
onAfterCleanModuleList
Description
This is an event that is called after the module list is cleaned.
Parameters
&modulesA reference to an array of rendered module objects
Return Value
None. Result will be omitted.