Line | |
---|
1 | <?php |
---|
2 | function plugin_install() |
---|
3 | { |
---|
4 | $q = ' |
---|
5 | INSERT INTO '.CONFIG_TABLE.' (param,value,comment) |
---|
6 | VALUES |
---|
7 | ("captcha_publickey","","Captcha public key") |
---|
8 | ;'; |
---|
9 | pwg_query($q); |
---|
10 | $q = ' |
---|
11 | INSERT INTO '.CONFIG_TABLE.' (param,value,comment) |
---|
12 | VALUES |
---|
13 | ("captcha_privatekey","","Captcha private key") |
---|
14 | ;'; |
---|
15 | pwg_query($q); |
---|
16 | } |
---|
17 | |
---|
18 | |
---|
19 | function plugin_uninstall() |
---|
20 | { |
---|
21 | foreach (array('captcha_publickey','captcha_privatekey') as $param) |
---|
22 | { |
---|
23 | $q = ' |
---|
24 | DELETE FROM '.CONFIG_TABLE.' WHERE param="'.$param.'" LIMIT 1'; |
---|
25 | pwg_query( $q ); |
---|
26 | } |
---|
27 | } |
---|
28 | |
---|
29 | ?> |
---|
Note: See
TracBrowser
for help on using the repository browser.