diff options
author | Renato Botelho <garga@FreeBSD.org> | 2015-02-24 08:20:04 -0300 |
---|---|---|
committer | Renato Botelho <garga@FreeBSD.org> | 2015-02-24 08:20:04 -0300 |
commit | 2fa6302094d89e78ba14ce12626f84ba2f92313e (patch) | |
tree | 56babf50195f723b67ebca2235b17b6248cb4100 /config/haproxy-devel/pkg/pkg_haproxy_tabs.inc | |
parent | fe029a6400adf6fe6efc3a302dde65138e674625 (diff) | |
parent | b21069b07582b7828edd781dfbcab72fbddc9c55 (diff) | |
download | pfsense-packages-2fa6302094d89e78ba14ce12626f84ba2f92313e.tar.gz pfsense-packages-2fa6302094d89e78ba14ce12626f84ba2f92313e.tar.bz2 pfsense-packages-2fa6302094d89e78ba14ce12626f84ba2f92313e.zip |
Merge pull request #827 from PiBa-NL/haproxy-devel21
Diffstat (limited to 'config/haproxy-devel/pkg/pkg_haproxy_tabs.inc')
-rw-r--r-- | config/haproxy-devel/pkg/pkg_haproxy_tabs.inc | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/config/haproxy-devel/pkg/pkg_haproxy_tabs.inc b/config/haproxy-devel/pkg/pkg_haproxy_tabs.inc new file mode 100644 index 00000000..a74ee20a --- /dev/null +++ b/config/haproxy-devel/pkg/pkg_haproxy_tabs.inc @@ -0,0 +1,28 @@ +<?php + +//require_once("guiconfig.inc"); DO NOT REQUIRE THIS! + +// DO NOT REQUIRE guiconfig.inc HERE! though it contains the function display_top_tabs needed below. +// however if included it will hang filter rule generation, and might cause pf to not load any rules. +// This happens when /usr/local/pkg/*.inc files are dynamically loaded during package generation from filter.inc with function discover_pkg_rules(x). + +global $haproxy_tab_array; + +$haproxy_tab_array['haproxy'] = array(); +$haproxy_tab_array['haproxy']['settings'] = Array(name => "Settings", url => "haproxy_global.php"); +$haproxy_tab_array['haproxy']['frontend'] = Array(name => "Frontend", url => "haproxy_listeners.php"); +$haproxy_tab_array['haproxy']['backend'] = Array(name => "Backend", url => "haproxy_pools.php"); +$haproxy_tab_array['haproxy']['files'] = Array(name => "Files", url => "haproxy_files.php"); +$haproxy_tab_array['haproxy']['stats'] = Array(name => "Stats", url => "haproxy_stats.php"); +$haproxy_tab_array['haproxy']['statsfs'] = Array(name => "Stats FS", url => "haproxy_stats.php?haproxystats=1"); +$haproxy_tab_array['haproxy']['templates'] = Array(name => "Templates", url => "haproxy_templates.php"); + +function haproxy_display_top_tabs_active($top_tabs, $activetab) { + $tab_array = array(); + foreach($top_tabs as $key => $tab_item){ + $tab_array[] = array($tab_item['name'], $key == $activetab, $tab_item['url']); + } + display_top_tabs($tab_array); +} + +?> |