Changeset 26061 for extensions/AdminTools/maintain.inc.php
- Timestamp:
- Dec 20, 2013, 9:14:40 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/AdminTools/maintain.inc.php
r25617 r26061 2 2 defined('PHPWG_ROOT_PATH') or die('Hacking attempt!'); 3 3 4 // class AdminTools_maintain extends PluginMaintain 5 // { 6 // private $installed = false; 4 class AdminTools_maintain extends PluginMaintain 5 { 6 private $installed = false; 7 8 private $default_conf = array( 9 'default_open' => true, 10 'closed_position' => 'left', 11 'public_quick_edit' => true, 12 ); 7 13 8 //function install($plugin_version, &$errors=array())9 //{10 //global $conf;14 function install($plugin_version, &$errors=array()) 15 { 16 global $conf; 11 17 12 // if (empty($conf['AdminTools'])) 13 // { 14 // $conf['AdminTools'] = serialize(array( 15 // )); 18 if (empty($conf['AdminTools'])) 19 { 20 $conf['AdminTools'] = serialize($this->default_conf); 21 conf_update_param('AdminTools', $conf['AdminTools']); 22 } 16 23 17 // conf_update_param('AdminTools', $conf['AdminTools']);18 //}24 $this->installed = true; 25 } 19 26 20 // $this->installed = true; 21 // } 27 function activate($plugin_version, &$errors=array()) 28 { 29 if (!$this->installed) 30 { 31 $this->install($plugin_version, $errors); 32 } 33 } 22 34 23 // function activate($plugin_version, &$errors=array()) 24 // { 25 // if (!$this->installed) 26 // { 27 // $this->install($plugin_version, $errors); 28 // } 29 // } 35 function deactivate() 36 { 37 } 30 38 31 // function deactivate() 32 // { 33 // } 34 35 // function uninstall() 36 // { 37 // conf_delete_param('AdminTools'); 38 // } 39 // } 39 function uninstall() 40 { 41 conf_delete_param('AdminTools'); 42 } 43 }
Note: See TracChangeset
for help on using the changeset viewer.