[geeklog-cvs] Geeklog-1.x/public_html/admin/plugins/spamx install.php, 1.20, 1.21

Dirk Haun dhaun at qs1489.pair.com
Sat Jan 26 13:31:33 EST 2008


Update of /cvsroot/geeklog/Geeklog-1.x/public_html/admin/plugins/spamx
In directory qs1489.pair.com:/tmp/cvs-serv89708/public_html/admin/plugins/spamx

Modified Files:
	install.php 
Log Message:
Updated plugin install


Index: install.php
===================================================================
RCS file: /cvsroot/geeklog/Geeklog-1.x/public_html/admin/plugins/spamx/install.php,v
retrieving revision 1.20
retrieving revision 1.21
diff -C2 -d -r1.20 -r1.21
*** install.php	11 Feb 2007 01:55:38 -0000	1.20
--- install.php	26 Jan 2008 18:31:31 -0000	1.21
***************
*** 3,7 ****
  /* Reminder: always indent with 4 spaces (no tabs). */
  // +---------------------------------------------------------------------------+
! // | Spam-X plugin 1.1.0                                                       |
  // +---------------------------------------------------------------------------+
  // | install.php                                                               |
--- 3,7 ----
  /* Reminder: always indent with 4 spaces (no tabs). */
  // +---------------------------------------------------------------------------+
! // | Spam-X plugin 1.1                                                         |
  // +---------------------------------------------------------------------------+
  // | install.php                                                               |
***************
*** 12,16 ****
  // | Based on the Universal Plugin and prior work by the following authors:    |
  // |                                                                           |
! // | Copyright (C) 2002-2006 by the following authors:                         |
  // |                                                                           |
  // | Authors: Tony Bibbs        - tony AT tonybibbs DOT com                    |
--- 12,16 ----
  // | Based on the Universal Plugin and prior work by the following authors:    |
  // |                                                                           |
! // | Copyright (C) 2002-2008 by the following authors:                         |
  // |                                                                           |
  // | Authors: Tony Bibbs        - tony AT tonybibbs DOT com                    |
***************
*** 39,44 ****
  // $Id$
  
! require_once ('../../../lib-common.php');
! require_once ($_CONF['path'] . 'plugins/spamx/config.php');
  
  // Plugin information
--- 39,43 ----
  // $Id$
  
! require_once '../../../lib-common.php';
  
  // Plugin information
***************
*** 48,53 ****
  $pi_display_name = 'Spam-X';
  $pi_name         = 'spamx';
! $pi_version      = $_SPX_CONF['version'];
! $gl_version      = '1.4.1';
  $pi_url          = 'http://www.pigstye.net/gplugs/staticpages/index.php/spamx';
  
--- 47,52 ----
  $pi_display_name = 'Spam-X';
  $pi_name         = 'spamx';
! $pi_version      = '1.1.1';
! $gl_version      = '1.5.0';
  $pi_url          = 'http://www.pigstye.net/gplugs/staticpages/index.php/spamx';
  
***************
*** 78,84 ****
  *
  */
! function plugin_compatible_with_this_geeklog_version ()
  {
!     if (function_exists ('PLG_spamAction')) {
          return true;
      }
--- 77,83 ----
  *
  */
! function plugin_compatible_with_this_geeklog_version()
  {
!     if (function_exists('PLG_spamAction')) {
          return true;
      }
***************
*** 86,89 ****
--- 85,110 ----
      return false;
  }
+ 
+ /**
+ * Add plugin configuration
+ *
+ */
+ function plugin_config()
+ {
+     global $_CONF, $pi_name;
+ 
+     require_once $_CONF['path_system'] . 'classes/config.class.php';
+ 
+     $c = config::get_instance();
+     $c->initConfig();
+     if (!$c->group_exists($pi_name)) {
+         $c->add('logging', true, 'select', 0, 0, 1, 10, true, 'spamx');
+         $c->add('admin_override', false, 'select', 0, 0, 1, 20, true, 'spamx');
+         $c->add('timeout', 5, 'text', 0, 0, null, 30, true, 'spamx');
+         $c->add('notification_email', '', 'text', 0, 0, null, 40, false, 'spamx');
+         $c->add('action', 128, 'text', 0, 0, null, 50, false, 'spamx');
+     }
+ }
+ 
  //
  // ----------------------------------------------------------------------------
***************
*** 94,104 ****
  $base_path = $_CONF['path'] . 'plugins/' . $pi_name . '/';
  $langfile = $base_path . $_CONF['language'] . '.php';
! if (file_exists ($langfile)) {
!     require_once ($langfile);
  } else {
!     require_once ($base_path . 'language/english.php');
  }
! require_once ($base_path . 'config.php');
! require_once ($base_path . 'functions.inc');
  
  
--- 115,124 ----
  $base_path = $_CONF['path'] . 'plugins/' . $pi_name . '/';
  $langfile = $base_path . $_CONF['language'] . '.php';
! if (file_exists($langfile)) {
!     require_once $langfile;
  } else {
!     require_once $base_path . 'language/english.php';
  }
! require_once $base_path . 'functions.inc';
  
  
***************
*** 227,230 ****
--- 247,254 ----
              return false;
          }
+     }
+ 
+     if (function_exists('plugin_config')) {
+         plugin_config();
      }
  




More information about the geeklog-cvs mailing list