JModuleHelper
Module helper class
package |
Joomla.Platform |
---|---|
subpackage |
Application |
since |
11.1 |
Methods
_load
Load published modules.
_load() : array
since |
11.1 |
---|
Response
array
getLayoutPath
Get the path to a layout for a module
getLayoutPath(string $module, string $layout = 'default') : string
since |
11.1 |
---|
Arguments
- $module
string
The name of the module- $layout
string
The name of the module layout. If alternative layout, in the form template:filename.
Response
string
The path to the module layout
getModule
Get module by name (real, eg 'Breadcrumbs' or folder, eg 'mod_breadcrumbs')
getModule(string $name, string $title = null) : object
since |
11.1 |
---|
Arguments
- $name
string
The name of the module- $title
string
The title of the module, optional
Response
object
The Module object
getModules
Get modules by position
getModules(string $position) : array
since |
11.1 |
---|
Arguments
- $position
string
The position of the module
Response
array
An array of module objects
isEnabled
Checks if a module is enabled
isEnabled(string $module) : boolean
since |
11.1 |
---|
Arguments
- $module
string
The module name
Response
boolean
moduleCache
Module cache helper
moduleCache(object $module, object $moduleparams, object $cacheparams) : string
Caching modes: To be set in XML: 'static' One cache file for all pages with the same module parameters 'oldstatic' 1.5 definition of module caching, one cache file for all pages with the same module id and user aid, 'itemid' Changes on itemid change, to be called from inside the module: 'safeuri' Id created from $cacheparams->modeparams array, 'id' Module sets own cache id's
since |
11.1 |
---|---|
link |
JFilterInput::clean() |
Arguments
- $module
object
Module object- $moduleparams
object
Module parameters- $cacheparams
object
Module cache parameters - id or url parameters, depending on the module cache mode
Response
string
renderModule
Render the module.
renderModule(object $module, array $attribs = array()) : string
since |
11.1 |
---|
Arguments
- $module
object
A module object.- $attribs
array
An array of attributes for the module (probably from the XML).
Response
string
The HTML content of the module output.