This wiki is under constant development, however pages are always missing. Create an account and login to be able to edit/create pages here.
 

Developing Plugins

Lilina is extended with PHP programs, known as plugins, which use the extension API. They extend the functionality of Lilina by replacing functions or using hooks. Read more on hooks


Please note that the following guide is out-of-date and should not be used as a reference. We will be updating this shortly.


Plugin information is kept in a comment at the top of each plugin. The following is an example:

    /*
    Plugin Name: Example
    Plugin URI: http://getlilina.org/docs/plugins:development
    Description: Just an example
    Author: Ryan McCue
    Version: 1.0
    Min Version: 1.0
    Author URI: http://cubegames.net
    Init: example_init
    */

Plugins must contain:

  • Plugin Name
  • Version

Plugins should contain:

  • Plugin URI
  • Description
  • Author
  • Version

Plugins can contain:

  • Min Version - Minimum version of Lilina required, if non-existent assumed to be current version
  • Init - Function called on activation of plugin
  • Author URI - Author’s website

Plugins should also check if the plugin system is the right version, as although the version of Lilina might change, the plugin system’s might not. The easiest way to do this is

    if($lilina['plugins-sys']['version'] >= 1.0) {
    //do stuff
    }
    else {
    trigger_plugin_error('version', 'Your version of Lilina is incompatible with this plugin');
    }

More information is coming soon.

 
plugins/development.txt · Last modified: 2007/12/31 17:05 by Ryan McCue