pastebin

Paste Search Dynamic
Recent pastes
example module
  1. <?php
  2. /**
  3.  * ADOdb Lite Example Module
  4.  *
  5.  * This example module can be used to create your own extention to ADOdb Lite.
  6.  *
  7.  * The module prefix name and class prefix name should all be the same and lowercase.
  8.  * If the new module name is 'blob' then rename this file to 'blob_module.inc'. Rename
  9.  * the following class designators.
  10.  *
  11.  * example_EXTENDER renamed to blob_EXTENDER
  12.  * example_ADOConnection renamed to blob_ADOConnection
  13.  * example_resultset_EXTENDER renamed to blob_resultset_EXTENDER
  14.  * example_ResultSet renamed to blob_ResultSet
  15.  *
  16.  * Functions that interact with the database should be placed inside the
  17.  * blob_ADOConnection class.  These are functions accessed using
  18.  * $db->function().
  19.  *
  20.  * Functions that interact with the resetset created by a query should
  21.  * be placed inside the blob_ResultSet class.  These are functions accessed using
  22.  * $result->function().
  23.  *
  24.  * Example:
  25.  * $result = $db->Execute($sql);
  26.  * echo $result->function();
  27.  *
  28.  * Place the file into the approriate database driver directory.  You should create one
  29.  * for each database you would like to support.
  30.  *
  31.  * To use your blob module start ADOdb Lite using.
  32.  *
  33.  * $db = ADONewConnection($databasetype, 'blob');
  34.  *
  35.  * Remember to replace every instance of mysql in the statements below with the database name
  36.  * the module is to be used.
  37.  *
  38.  */
  39.  
  40. eval('class mysql_example_EXTENDER extends '. $last_module . '_ADOConnection { }');
  41.  
  42. class mysql_example_ADOConnection extends mysql_example_EXTENDER
  43. {
  44. }
  45.  
  46. eval('class mysql_example_resultset_EXTENDER extends '. $last_module . '_ResultSet { }');
  47.  
  48. class mysql_example_ResultSet extends mysql_example_resultset_EXTENDER
  49. {
  50. }
  51. ?>
Parsed in 0.009 seconds