liberty
[ class tree: liberty ] [ index: liberty ] [ all elements ]

Source for file data.example.php

Documentation is available at data.example.php

  1. <?php
  2. /**
  3.  * @version  $Revision$
  4.  * @package  liberty
  5.  * @subpackage plugins_data
  6.  */
  7. // +----------------------------------------------------------------------+
  8. // | Copyright (c) 2004, bitweaver.org
  9. // +----------------------------------------------------------------------+
  10. // | All Rights Reserved. See below for details and a complete list of authors.
  11. // | Licensed under the GNU LESSER GENERAL PUBLIC LICENSE. See http://www.gnu.org/copyleft/lesser.html for details
  12. // |
  13. // | For comments, please use phpdocu.sourceforge.net documentation standards!!!
  14. // | -> see http://phpdocu.sourceforge.net/
  15. // +----------------------------------------------------------------------+
  16. // | Author: StarRider starrrider@sourceforge.net
  17. // +----------------------------------------------------------------------+
  18. // $id: data.example.php,v 1.4.2.9 2005/07/14 09:03:36 starrider Exp $
  19.  
  20. /******************
  21.  * Initialization *
  22.  ******************/
  23. define'PLUGIN_GUID_DATAEXAMPLE''dataexample' );
  24. global $gLibertySystem;
  25. $pluginParams array 'tag' => 'EXAM',
  26.     'auto_activate' => FALSE,
  27.     'requires_pair' => FALSE,
  28.     'load_function' => 'data_example',
  29.     'title' => 'Example',
  30.     'help_page' => 'DataPluginExample',
  31.     'description' => tra("This Plugin is an Example that does nothing. It functions as a template for the creation of new plugins."),
  32.     'help_function' => 'data_example_help',
  33.     'syntax' => "{EXAM x1= x2= }",
  34.     'plugin_type' => DATA_PLUGIN
  35. );
  36. $gLibertySystem->registerPluginPLUGIN_GUID_DATAEXAMPLE$pluginParams );
  37. $gLibertySystem->registerDataTag$pluginParams['tag']PLUGIN_GUID_DATAEXAMPLE );
  38. /*****************
  39.  * Help Function *
  40.  *****************/
  41. function data_example_help({
  42.     $help =
  43.         '<table class="data help">'
  44.             .'<tr>'
  45.                 .'<th>' tra"Key" '</th>'
  46.                 .'<th>' tra"Type" '</th>'
  47.                 .'<th>' tra"Comments" '</th>'
  48.             .'</tr>'
  49.             .'<tr class="odd">'
  50.                 .'<td>x1</td>'
  51.                 .'<td>' tra"string"'<br />' tra("(optional)"'</td>'
  52.                 .'<td>' tra"Specifies something / probably to be displayed.")
  53.                     .'<br />' tra"The Default = <strong>Sorry About That</strong>")
  54.                 .'</td>'
  55.             .'</tr>'
  56.             .'<tr class="even">'
  57.                 .'<td>XXX</td>'
  58.                 .'<td>' tra"number"'<br />' tra("(optional)"'</td>'
  59.                 .'<td>' tra"Specifies something / probably to be displayed.")
  60.                     .'<br />' tra"The Default ="' <strong>3</strong> ' tra"Which means - What")
  61.                 .'</td>'
  62.             .'</tr>'
  63.          .'</table>'
  64.         . tra("Example: ""{EXAM x1=' ' x2=5 }<br />"
  65.         . tra("This will display");
  66.     return $help;
  67. }
  68. /****************
  69. * Load Function *
  70.  ****************/
  71. function data_example($data$params{
  72.     extract ($paramsEXTR_SKIP);
  73.     $ret ' ';
  74.  
  75.     return $ret;
  76. }
  77. ?>

Documentation generated on Wed, 29 Jul 2015 13:56:19 +0000 by phpDocumentor 1.5.0-lsces