Class Plugin

Description

Habari Plugin Class

Template plugin object which specific plugin objects should extend This object provides the basic constructor used to ensure that plugin actions are registered against the appropriate dispatcher

  • version: $Id$
  • copyright: 2008
  • abstract:

Located in /system/classes/plugin.php (line 12)

Pluggable
   |
   --Plugin
Direct descendents
Class Description
WPImport WordPress Importer - Imports data from WordPress into Habari
SpamChecker SpamChecker Class
Undelete Undelete Class
Pingback Habari Pingback plugin, enables pingback support between sites.
HabariSilo Simple file access silo
FlickrSilo Flickr Silo
ThemeHelper ThemeHelper - Provides additional functions that may be useful to some themes.
ViddlerSilo Viddler Silo
S9YImport Serendipity Importer - Imports data from Serendipity into Habari
CoreDashModules CoreDashModules - Provides a core set of dashboard modules for the dashboard.
Method Summary
Plugin __construct ()
void add_template (string $name, string $filename, [boolean $override = false])
array info ()
array _plugin_available_templates (array $list)
string _plugin_include_template_file (string $file, string $name)
Variables

Inherited Variables

Inherited from Pluggable

Pluggable::$info
Pluggable::$plugin_id
Methods
Constructor __construct (line 28)

Plugin constructor.

Plugins should not define their own constructors, because they are instantiated to extract plugin info. Instead, include a sink for a "init" hook which is executed immediately after the plugin is loaded during normal execution.

  • access: public
Plugin __construct ()

Redefinition of:
Pluggable::__construct()
Pluggable constructor.
add_template (line 44)

Adds a template to the default theme that is stored in a specified path.

Use this function as a shortcut to make available additional templates to a theme from within the plugin directory.

  • access: protected
void add_template (string $name, string $filename, [boolean $override = false])
  • string $name: The name of the template that will be displayed, sans extension
  • string $filename: The full path of the template file used for the specified name
  • boolean $override: If false, allow a template with the same name in the active theme directory to override this one. If true, always override the active theme's template with this one.
info (line 20)

Returns information about this plugin

  • return: An associative array of information about this plugin
  • abstract:
  • access: public
array info ()

Redefined in descendants as:
_plugin_available_templates (line 60)

Add plugin templates to the list of templates that are present in the current theme

  • return: The modified list of template names
  • access: public
array _plugin_available_templates (array $list)
  • array $list: List of template names in the current theme
_plugin_include_template_file (line 73)

Potentially serve a different file for the requested template name

  • return: The potentially modified filename to use for the requested template.
  • access: public
string _plugin_include_template_file (string $file, string $name)
  • string $file: The filename of the template the theme will display
  • string $name: The name of the template requested

Inherited Methods

Inherited From Pluggable

Pluggable::__construct()
Pluggable::get_db_schema()
Pluggable::get_file()
Pluggable::get_url()
Pluggable::load()
Pluggable::load_text_domain()
Pluggable::plugin_id()

Documentation generated on Thu, 30 Oct 2008 20:31:22 +0100 by phpDocumentor 1.3.2