source: extensions/LLGBO2/admin/header.php

Last change on this file was 29862, checked in by gbo, 10 years ago

Fix notice during installation or activation

File size: 1.2 KB
Line 
1<?php
2// Update configuration settings in database
3 
4// +-----------------------------------------------------------------------+
5/////            HEADER
6// +-----------------------------------------------------------------------+
7if ($page['tab'] == 'header') {
8        if ( isset($_POST['save'])) 
9                        {       foreach($default_header['HD-dispheader'] as $cle => $valeur)
10                                                { $param_llgbo_header['HD-dispheader'][$cle] = (empty($_POST[$cle])) ? False : True;
11                                                }       
12                                $conf['LLGBO2'] = update_llgboconf($conf['LLGBO2'],$param_llgbo_header );
13                                // $conf['LLGBO2'] = array_replace($conf['LLGBO2'],$param_llgbo_header );
14                               
15                                // Update DB
16                                conf_update_param('LLGBO2_settings',$conf['LLGBO2'],true); 
17                                array_push($page['infos'], l10n('Information data registered in database'));   
18                        }               
19                               
20        if ( isset($_POST['reset']) ) 
21                        {  $conf['LLGBO2'] = update_llgboconf($conf['LLGBO2'], $default_header );
22                                // $conf['LLGBO2'] = array_replace($conf['LLGBO2'], $default_header);
23                        }
24
25 // Reload settings for correct display after update
26   $template->assign('LLGBO_DISP_HEADER', $conf['LLGBO2']['HD-dispheader']);
27   $template->assign('LLGBO_PREFIXE_HEADER','llgbo_header_');
28}
29
30?>
31
Note: See TracBrowser for help on using the repository browser.