[ Index ]

PHP Cross Reference of Joomla 4.2.2 documentation

title

Body

[close]

/libraries/src/Component/ -> ComponentHelper.php (summary)

Joomla! Content Management System

Copyright: (C) 2006 Open Source Matters, Inc.
License: GNU General Public License version 2 or later; see LICENSE.txt
File Size: 452 lines (15 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

ComponentHelper:: (9 methods):
  getComponent()
  isEnabled()
  isInstalled()
  getParams()
  filterText()
  renderComponent()
  load()
  getComponents()
  getComponentName()


Class: ComponentHelper  - X-Ref

Component helper class

getComponent($option, $strict = false)   X-Ref
Get the component information.

param: string   $option  The component option.
param: boolean  $strict  If set and the component does not exist, the enabled attribute will be set to false.
return: ComponentRecord  An object with the information for the component.

isEnabled($option)   X-Ref
Checks if the component is enabled

param: string  $option  The component option.
return: boolean

isInstalled($option)   X-Ref
Checks if a component is installed

param: string  $option  The component option.
return: integer

getParams($option, $strict = false)   X-Ref
Gets the parameter object for the component

param: string   $option  The option for the component.
param: boolean  $strict  If set and the component does not exist, false will be returned
return: Registry  A Registry object.

filterText($text)   X-Ref
Applies the global text filters to arbitrary text as per settings for current user groups

param: string  $text  The string to filter
return: string  The filtered string

renderComponent($option, $params = array()   X-Ref
Render the component.

param: string  $option  The component option.
param: array   $params  The component parameters
return: string

load()   X-Ref
Load the installed components into the components property.

return: boolean  True on success

getComponents()   X-Ref
Get installed components

return: ComponentRecord[]  The components property

getComponentName($object, string $alternativeName)   X-Ref
Returns the component name (eg. com_content) for the given object based on the class name.
If the object is not namespaced, then the alternative name is used.

param: object  $object           The object controller or model
param: string  $alternativeName  Mostly the value of getName() from the object
return: string  The name



Generated: Wed Sep 7 05:41:13 2022 Chilli.vc Blog - For Webmaster,Blog-Writer,System Admin and Domainer