API15

JComponentHelper/isEnabled

From Joomla! Documentation

< API15:JComponentHelper

The "API15" namespace is an archived namespace. This page contains information for a Joomla! version which is no longer supported. It exists only as a historical reference, it will not be improved and its content may be incomplete and/or contain broken links.

Description[edit]

Checks if the component is enabled

[<! removed edit link to red link >]

<! removed transcluded page call, red link never existed >

Syntax[edit]

isEnabled($component, $strict=false)
Parameter Name Default Value Description
$component $component The component name
$strict false $string If set and a component does not exist, false will be returned

Returns[edit]

boolean

Defined in[edit]

libraries/joomla/application/component/helper.php

Importing[edit]

jimport( 'joomla.application.component.helper' );

Source Body[edit]

function isEnabled( $component, $strict = false )
{
        global $mainframe;

        $result = &JComponentHelper::getComponent( $component, $strict );
        return ($result->enabled | $mainframe->isAdmin());
}

[<! removed edit link to red link >] <! removed transcluded page call, red link never existed >

Examples[edit]

Code Examples[edit]