Changeset 5162 for extensions/nbc_HistoryIPExcluder/trunk/maintain.inc.php
- Timestamp:
- Mar 17, 2010, 5:44:07 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/nbc_HistoryIPExcluder/trunk/maintain.inc.php
r5121 r5162 9 9 $q = ' 10 10 INSERT INTO '.CONFIG_TABLE.' (param,value,comment) 11 VALUES (" nbc_HistoryIPExcluder","","Parametres nbc History IP Excluder");11 VALUES ("HistoryIPExcluder","","History IP Excluder parameters"); 12 12 '; 13 13 14 14 pwg_query($q); 15 } 16 17 18 function plugin_activate() 19 { 20 global $conf; 21 22 /* Check for upgrade from 2.0.0 to 2.0.1 */ 23 /* *************************************** */ 24 $query = ' 25 SELECT param 26 FROM '.CONFIG_TABLE.' 27 WHERE param = "nbc_HistoryIPExcluder" 28 ;'; 29 $count = mysql_num_rows(pwg_query($query)); 30 31 if ($count == 1) 32 { 33 /* upgrade from branch 2.0.0 to 2.0.1 */ 34 /* ************************************ */ 35 upgrade_200(); 36 } 15 37 } 16 38 … … 31 53 } 32 54 55 56 function upgrade_200() 57 { 58 global $conf; 59 60 $q = ' 61 UPDATE '.CONFIG_TABLE.' 62 SET param = "HistoryIPExcluder" 63 WHERE param = "nbc_HistoryIPExcluder" 64 ;'; 65 pwg_query($q); 66 67 $q = ' 68 UPDATE '.CONFIG_TABLE.' 69 SET comment = "History IP Excluder parameters" 70 WHERE comment = "Parametres nbc History IP Excluder" 71 ;'; 72 pwg_query($q); 73 } 33 74 ?>
Note: See TracChangeset
for help on using the changeset viewer.