$timezone) {
if (strpos($timezone, $zone) === false) {
unset($timezones[$timezone_key]);
}
}
echo json_encode($timezones);
}
return;
}
if (! check_acl ($config['id_user'], 0, "PM") && ! is_user_admin ($config['id_user'])) {
db_pandora_audit("ACL Violation", "Trying to access Setup Management");
require ("general/noaccess.php");
return;
}
// Load enterprise extensions
enterprise_include_once ('include/functions_setup.php');
enterprise_include_once ('godmode/setup/setup.php');
/*
NOTICE FOR DEVELOPERS:
Update operation is done in config_process.php
This is done in that way so the user can see the changes inmediatly.
If you added a new token, please check config_update_config() in functions_config.php
to add it there.
*/
// Gets section to jump to another section
$section = (string) get_parameter ("section", "general");
$buttons = array();
// Draws header
$buttons['general'] = array('active' => false,
'text' => '' .
html_print_image("images/gm_setup.png", true, array ("title" => __('General'))) . '');
if (enterprise_installed()) {
$buttons = setup_enterprise_add_Tabs($buttons);
}
$buttons['auth'] = array('active' => false,
'text' => '' .
html_print_image("images/key.png", true, array ("title" => __('Authentication'))) . '');
$buttons['perf'] = array('active' => false,
'text' => '' .
html_print_image("images/performance.png", true, array ("title" => __('Performance'))) . '');
$buttons['vis'] = array('active' => false,
'text' => '' .
html_print_image("images/chart.png", true, array ("title" => __('Visual styles'))) . '');
if (check_acl ($config['id_user'], 0, "AW")) {
if ($config['activate_netflow']) {
$buttons['net'] = array('active' => false,
'text' => '' .
html_print_image("images/op_netflow.png", true, array ("title" => __('Netflow'))) . '');
}
}
$help_header = '';
if (enterprise_installed()) {
$subpage = setup_enterprise_add_subsection_main($section, $buttons, $help_header);
}
switch ($section) {
case 'general':
$buttons['general']['active'] = true;
$subpage = ' » ' . __('General');
break;
case 'auth':
$buttons['auth']['active'] = true;
$subpage = ' » ' . __('Authentication');
break;
case 'perf':
$buttons['perf']['active'] = true;
$subpage = ' » ' . __('Performance');
$help_header = 'performance';
break;
case 'vis':
$buttons['vis']['active'] = true;
$subpage = ' » ' . __('Visual styles');
break;
case 'net':
$buttons['net']['active'] = true;
$subpage = ' » ' . __('Netflow');
break;
}
// Header
ui_print_page_header (__('Configuration') . $subpage, "", false, $help_header, true, $buttons);
if (isset($config['error_config_update_config'])) {
if ($config['error_config_update_config']['correct'] == false) {
ui_print_error_message($config['error_config_update_config']['message']);
}
else {
ui_print_success_message(__('Correct update the setup options'));
}
unset($config['error_config_update_config']);
}
switch ($section) {
case "general":
require_once($config['homedir'] . "/godmode/setup/setup_general.php");
break;
case "auth":
require_once($config['homedir'] . "/godmode/setup/setup_auth.php");
break;
case "perf":
require_once($config['homedir'] . "/godmode/setup/performance.php");
break;
case "net":
require_once($config['homedir'] . "/godmode/setup/setup_netflow.php");
break;
case "vis":
require_once($config['homedir'] . "/godmode/setup/setup_visuals.php");
break;
default:
enterprise_hook('setup_enterprise_select_tab', array($section));
break;
}
?>