source: extensions/UserCollections/maintain.inc.php @ 23833

Last change on this file since 23833 was 23551, checked in by mistic100, 11 years ago

many corrections & optimizations + remove useless code + clean

File size: 756 bytes
Line 
1<?php
2if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!');
3
4defined('USER_COLLEC_ID') or define('USER_COLLEC_ID', basename(dirname(__FILE__)));
5include_once(PHPWG_PLUGINS_PATH . USER_COLLEC_ID . '/include/install.inc.php');
6
7function plugin_install() 
8{
9  user_collections_install();
10 
11  define('user_collections_installed', true);
12}
13
14function plugin_activate()
15{
16  if (!defined('user_collections_intalled'))
17  {
18    user_collections_install();
19  }
20}
21
22function plugin_uninstall() 
23{
24  global $prefixeTable;
25 
26  pwg_query('DELETE FROM `'. CONFIG_TABLE .'` WHERE param = "user_collections" LIMIT 1;');
27  pwg_query('DROP TABLE IF EXISTS `'.$prefixeTable.'collections`;');
28  pwg_query('DROP TABLE IF EXISTS `'.$prefixeTable.'collection_images`;');
29}
30
31?>
Note: See TracBrowser for help on using the repository browser.