Line | |
---|
1 | <?php |
---|
2 | |
---|
3 | if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!'); |
---|
4 | |
---|
5 | |
---|
6 | function plugin_install() |
---|
7 | { |
---|
8 | $query = 'INSERT INTO ' . CONFIG_TABLE . ' (param,value,comment) VALUES ("Photo_add_by","datecreate","Photo_add_by");'; |
---|
9 | pwg_query($query); |
---|
10 | } |
---|
11 | |
---|
12 | function plugin_activate() |
---|
13 | { |
---|
14 | global $conf; |
---|
15 | if (empty($conf['Photo_add_by'])) |
---|
16 | { |
---|
17 | $query = 'INSERT INTO ' . CONFIG_TABLE . ' (param,value,comment) VALUES ("Photo_add_by","datecreate","Photo_add_by");'; |
---|
18 | pwg_query($query); |
---|
19 | } |
---|
20 | } |
---|
21 | |
---|
22 | |
---|
23 | function plugin_uninstall() |
---|
24 | { |
---|
25 | $q = 'DELETE FROM ' . CONFIG_TABLE . ' WHERE param="Photo_add_by" LIMIT 1;'; |
---|
26 | pwg_query($q); |
---|
27 | } |
---|
28 | ?> |
---|
Note: See
TracBrowser
for help on using the repository browser.