API16

API16:JPluginHelper/isEnabled

From Joomla! Documentation

Revision as of 22:36, 22 March 2010 by Doxiki (talk | contribs) (New page: ===Description=== Checks if a plugin is enabled. <span class="editsection" style="font-size:76%;"> <nowiki>[</nowiki>Edit Descripton<nowiki>]</...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Description

Checks if a plugin is enabled.

[Edit Descripton]

Template:Description:JPluginHelper/isEnabled

Syntax

static isEnabled($type, $plugin=null)
Parameter Name Default Value Description
$type $type The plugin type, relates to the sub-directory in the plugins directory.
$plugin null $plugin The plugin name.

Returns

boolean

Defined in

libraries/joomla/plugin/helper.php

Importing

jimport( 'joomla.plugin.helper' );

Source Body

public static function isEnabled($type, $plugin = null)
{
        $result = &self::getPlugin($type, $plugin);
        return (!empty($result));
}

[Edit See Also] Template:SeeAlso:JPluginHelper/isEnabled

Examples

<CodeExamplesForm />