Line | |
---|
1 | <?php |
---|
2 | |
---|
3 | function theme_activate($id, &$errors) |
---|
4 | { |
---|
5 | global $conf; |
---|
6 | |
---|
7 | if (!isset($conf['Junk'])) |
---|
8 | { |
---|
9 | $config = array( |
---|
10 | 'style' => 'green', |
---|
11 | 'tab' =>'0', |
---|
12 | ); |
---|
13 | |
---|
14 | $query = " |
---|
15 | INSERT INTO " . CONFIG_TABLE . " (param,value,comment) |
---|
16 | VALUES ('Junk' , '".pwg_db_real_escape_string(serialize($config))."' , 'Junk theme parameters');"; |
---|
17 | |
---|
18 | pwg_query($query); |
---|
19 | } |
---|
20 | } |
---|
21 | |
---|
22 | function theme_deactivate() |
---|
23 | { |
---|
24 | |
---|
25 | $query = "DELETE FROM " . CONFIG_TABLE . " WHERE param='Junk';"; |
---|
26 | pwg_query($query); |
---|
27 | } |
---|
28 | |
---|
29 | ?> |
---|
Note: See
TracBrowser
for help on using the repository browser.