Get the only permitted instance of this object. It will be created if necessary
static
object
&get_instance
()
Returns an array of installed modules that have a certain capabilies This method will force the loading of all modules regardless of the module settings.
static
array
get_modules_with_capability
(string $capability, [mixed $args = ''])
-
string
$capability: The capability name
-
mixed
$args: Capability arguments
Activate a module
boolean
ActivateModule
(string $module_name, [boolean $activate = true])
-
string
$module_name: module name
-
boolean
$activate: flag indicating wether to activate or deactivate the module
Creates an xml data package from the module directory.
string
CreateXMLPackage
( &$modinstance, &$message, &$filecount, mixed $modinstance, string $message, integer $filecount)
-
mixed
$modinstance: The instance of the module object
-
string
$message: Reference to a string which will be filled with the message created by the run of the method
-
integer
$filecount: Reference to an interger which will be filled with the total # of files in the package
-
&$modinstance
-
&$message
-
&$filecount
Unpackage a module from an xml string does not touch the database
array
ExpandXMLPackage
( $xmluri, [boolean $overwrite = 0], [boolean $brief = 0], string $xml)
-
string
$xml: The xml data for the package
-
boolean
$overwrite: Should we overwrite files if they exist?
-
boolean
$brief: If set to true, less checking is done and no errors are returned
-
$xmluri
A function to return a list of all modules that appear to exist properly in the modules directory.
array
FindAllModules
()
Return an array of the names of all modules that we currently know about
void
GetAllModuleNames
()
Returns an array of the names of all installed modules.
array
GetInstalledModules
([ $include_all = FALSE])
Returns a hash of all loaded modules. This will include all modules loaded into memory at the current time
array
&GetLoadedModules
()
Get list of modules queued for install.
void
GetQueueResults
(string 0)
Return the current search module object
This method returns module object for the currently selected search module.
null
&GetSearchModule
()
Return the current syntax highlighter module object
This method retrieves the specified syntax highlighter module, or uses the current current user preference for the syntax hightlighter module for a name.
null
&GetSyntaxHighlighter
([string $module_name = ''])
-
string
$module_name: allows bypassing the automatic detection process and specifying a wysiwyg module.
Alias for the GetSyntaxHiglighter method.
void
&GetSyntaxModule
([ $module_name = ''])
Return the current wysiwyg module object
This method makes an attempt to find the appropriate wysiwyg module given the current request context and admin user preference.
null
&GetWYSIWYGModule
([string $module_name = ''])
-
string
$module_name: allows bypassing the automatic detection process and specifying a wysiwyg module.
A function to return the object reference to the module object if the module is not already loaded, it will be loaded. Version checks are done with the module to allow only loading versions of modules that are greater than the specified value.
mixed
&get_module_instance
(string $module_name, [string $version = ''], [boolean $force = FALSE])
-
string
$module_name: The module name
-
string
$version: an optional version string.
-
boolean
$force: an optional flag to indicate wether the module should be force loaded if necesary.
Install a module into the database
array
InstallModule
(string $module, [boolean $loadifnecessary = false])
-
string
$module: The name of the module to install
-
boolean
$loadifnecessary: If true, loads the module before trying to install it
Test if a module is active
void
IsModuleActive
( $module_name)
Test if the specified module name is a system module
boolean
IsSystemModule
(string $module_name)
-
string
$module_name: The module name
Finds all modules that are available to be loaded...
this method uses the information in the database to load the modules that are necessary to load it also, will go through any queued installs/upgrades and force those modules to load, which will in turn do the upgrading and installing if necessary.
void
LoadModules
([loadall $loadall = false], [noadmin $noadmin = false], [no_lazyload $no_lazyload = false])
-
loadall
$loadall: boolean indicates wether ALL modules in the filesystem should be loaded, default is false
-
noadmin
$noadmin: boolean indicates that modules marked as admin_only in the database should not be loaded, default is false
-
no_lazyload
$no_lazyload: boolean indicates that modules marked as lazy_loadable should be loaded anywayz, default is falze
Queue a module for install
void
QueueForInstall
(string $module_name)
-
string
$module_name: module name
Uninstall a module
boolean
UninstallModule
(string $module)
-
string
$module: The name of the module to upgrade
Unload a module from memory
void
unload_module
(string $module_name)
-
string
$module_name: module name
Upgrade a module
This is an internal method, subject to change in later releases. It should never be called for upgrading arbitrary modules. Any use of this function by third party code will not be supported. Use at your own risk and do not report bugs or issues related to your use of this module.
boolean
UpgradeModule
( $module_name, [ $to_version = ''], string $module)
-
string
$module: The name of the module to upgrade
-
$module_name
-
$to_version