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