[geeklog-cvs] Geeklog-1.x/sql/updates mysql_1.4.1_to_1.5.0.php, 1.69, 1.70

Dirk Haun dhaun at qs1489.pair.com
Sun Mar 16 08:22:04 EDT 2008


Update of /cvsroot/geeklog/Geeklog-1.x/sql/updates
In directory qs1489.pair.com:/tmp/cvs-serv34111/sql/updates

Modified Files:
	mysql_1.4.1_to_1.5.0.php 
Log Message:
Calender plugin configuration


Index: mysql_1.4.1_to_1.5.0.php
===================================================================
RCS file: /cvsroot/geeklog/Geeklog-1.x/sql/updates/mysql_1.4.1_to_1.5.0.php,v
retrieving revision 1.69
retrieving revision 1.70
diff -C2 -d -r1.69 -r1.70
*** mysql_1.4.1_to_1.5.0.php	15 Mar 2008 18:11:43 -0000	1.69
--- mysql_1.4.1_to_1.5.0.php	16 Mar 2008 12:22:02 -0000	1.70
***************
*** 364,368 ****
  
      if (file_exists($plugin_path . 'config.php')) {
!         global $_PO_CONF;
  
          require_once $plugin_path . 'config.php';
--- 364,368 ----
  
      if (file_exists($plugin_path . 'config.php')) {
!         global $_DB_table_prefix, $_PO_CONF;
  
          require_once $plugin_path . 'config.php';
***************
*** 443,447 ****
  
      if (file_exists($plugin_path . 'config.php')) {
!         global $_SP_CONF;
  
          require_once $plugin_path . 'config.php';
--- 443,447 ----
  
      if (file_exists($plugin_path . 'config.php')) {
!         global $_DB_table_prefix, $_SP_CONF;
  
          require_once $plugin_path . 'config.php';
***************
*** 479,483 ****
  function upgrade_CalendarPlugin()
  {
!     global $_TABLES, $_STATES;
  
      $P_SQL[] = "ALTER TABLE {$_TABLES['events']} CHANGE state state varchar(40) default NULL";
--- 479,499 ----
  function upgrade_CalendarPlugin()
  {
!     global $_CONF, $_TABLES, $_STATES;
! 
!     require_once $_CONF['path_system'] . 'classes/config.class.php';
! 
!     $plugin_path = $_CONF['path'] . 'plugins/calendar/';
!     require_once $plugin_path . 'install_defaults.php';
! 
!     if (file_exists($plugin_path . 'config.php')) {
!         global $_DB_table_prefix, $_CA_CONF;
! 
!         require_once $plugin_path . 'config.php';
!     }
! 
!     if (!plugin_initconfig_calendar()) {
!         echo 'There was an error upgrading the Polls plugin';
!         return false;
!     }
  
      $P_SQL[] = "ALTER TABLE {$_TABLES['events']} CHANGE state state varchar(40) default NULL";
***************
*** 506,509 ****
--- 522,531 ----
      }
  
+     if (file_exists($plugin_path . 'config.php')) {
+         // Rename the existing config.php as it's not needed any more
+         $ren = @rename($plugin_path . 'config.php',
+                        $plugin_path . 'config-pre1.5.0.php');
+     }
+ 
      return true;
  }
***************
*** 520,524 ****
  
      if (file_exists($plugin_path . 'config.php')) {
!         global $_SPX_CONF;
  
          require_once $plugin_path . 'config.php';
--- 542,546 ----
  
      if (file_exists($plugin_path . 'config.php')) {
!         global $_DB_table_prefix, $_SPX_CONF;
  
          require_once $plugin_path . 'config.php';
***************
*** 555,558 ****
--- 577,586 ----
      $plugin_path = $_CONF['path'] . 'plugins/links/';
      require_once $plugin_path . 'install_defaults.php';
+ 
+     if (file_exists($plugin_path . 'config.php')) {
+         global $_DB_table_prefix, $_LI_CONF;
+ 
+         require_once $plugin_path . 'config.php';
+     }
  
      if (!plugin_initconfig_links()) {




More information about the geeklog-cvs mailing list