/functions/plugin.php

Description

plugin.php

This file provides the framework for a plugin architecture.

Documentation on how to write plugins might show up some time.

Includes
require_once (SM_PATH.'functions/global.php') (line 17)

Everything needs global..

Functions
boolean_hook_function (line 128)

This function is used for hooks which are to return true or false. If $priority is > 0, any one or more trues will override any falses. If $priority < 0, then one or more falses will override any trues.

Priority 0 means majority rules. Ties will be broken with $tie

  • return: the result of the function
bool boolean_hook_function (mixed $name, [mixed $parm = NULL], [mixed $priority = 0], [mixed $tie = false])
concat_hook_function (line 96)

This function executes a hook, concatenating the results of each plugin that has the hook defined.

  • return: a concatenation of the results of each plugin function
string concat_hook_function (mixed $name, [mixed $parm = NULL])
do_hook (line 42)

This function executes a hook.

mixed do_hook (string $name)
  • string $name: Name of hook to fire
do_hook_function (line 69)

This function executes a hook and allows for parameters to be passed.

  • return: the return value of the hook function
mixed do_hook_function (mixed $name, [mixed $parm = NULL])
soupNazi (line 176)

This function checks whether the user's USER_AGENT is known to be broken. If so, returns true and the plugin is invisible to the offending browser.

*** THIS IS A TEST FOR JAVASCRIPT SUPPORT *** FIXME: This function needs to have its name changed!

  • return: whether this browser properly supports JavaScript
bool soupNazi ()
use_plugin (line 27)

This function adds a plugin.

void use_plugin (string $name)
  • string $name: Internal plugin name (ie. delete_move_next)

Documentation generated on Sat, 07 Oct 2006 16:33:02 +0300 by phpDocumentor 1.3.0RC6