source: extensions/blancmontxl/admin/admin.inc.php @ 6286

Last change on this file since 6286 was 6286, checked in by repie38, 14 years ago

conf panel new option : use montblancxl icon set (option can't be set if montblancxl isn't installed)

File size: 908 bytes
Line 
1<?php
2
3load_language('theme.lang', PHPWG_THEMES_PATH.'blancmontxl/');
4
5$options = array(
6  'home',
7  'categories',
8  'picture',
9  'other',
10  'ico',
11);
12
13if (isset($_POST['submit']))
14{
15  foreach ($options as $option)
16  {
17    $_POST['bmxl'][$option] = empty($_POST['bmxl'][$option]) ? false : true;
18  }
19 
20  $_POST['bmxl']['ico'] = file_exists('themes/montblancxl/icon/add_tag.png') ? $_POST['bmxl']['ico'] : false ;
21
22  $query = '
23UPDATE '.CONFIG_TABLE.'
24SET value = "'.addslashes(serialize($_POST['bmxl'])).'"
25WHERE param = "BlancmontXL"
26;';
27  pwg_query($query);
28
29  array_push($page['infos'], l10n('Information data registered in database'));
30
31  load_conf_from_db();
32}
33
34$template->set_filenames(array(
35    'theme_admin_content' => dirname(__FILE__) . '/admin.tpl'));
36
37$template->assign('bmxl', unserialize($conf['BlancmontXL']));
38
39$template->assign_var_from_handle('ADMIN_CONTENT', 'theme_admin_content');
40
41
42?>
Note: See TracBrowser for help on using the repository browser.