summaryrefslogtreecommitdiffstats
path: root/usr/local/www/fbegin.inc
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2012-08-10 15:30:20 -0400
committerjim-p <jimp@pfsense.org>2012-08-10 15:30:20 -0400
commit6d9b107442c111b7ef164cce6e7ecabd39622ddb (patch)
treecb6b9f2d81a191bf368c477e6783b8549ff107d9 /usr/local/www/fbegin.inc
parent7d7b5a48551381e8d29a671595a1baab8008932c (diff)
downloadpfsense-6d9b107442c111b7ef164cce6e7ecabd39622ddb.zip
pfsense-6d9b107442c111b7ef164cce6e7ecabd39622ddb.tar.gz
Fixup openvpn shortcut bar status/control
Diffstat (limited to 'usr/local/www/fbegin.inc')
-rwxr-xr-xusr/local/www/fbegin.inc18
1 files changed, 15 insertions, 3 deletions
diff --git a/usr/local/www/fbegin.inc b/usr/local/www/fbegin.inc
index edd4592..d784d81 100755
--- a/usr/local/www/fbegin.inc
+++ b/usr/local/www/fbegin.inc
@@ -390,9 +390,21 @@ function add_to_menu($url, $name) {
<span style="float:right; margin: 0 0 20px 20px">
<?php
if (!$hide_service_status && !empty($shortcuts[$shortcut_section]['service'])) {
- $ssvc = find_service_by_name($shortcuts[$shortcut_section]['service']);
- echo get_service_status_icon($ssvc, false);
- echo get_service_control_links($ssvc, true);
+ switch ($shortcut_section) {
+ case "openvpn":
+ $ssvc = find_service_by_openvpn_vpnid($vpnid);
+ break;
+ case "captiveportal":
+ $ssvc = find_service_by_cp_zone($cpzone);
+ break;
+ default:
+ $ssvc = find_service_by_name($shortcuts[$shortcut_section]['service']);
+
+ }
+ if (!empty($ssvc)) {
+ echo get_service_status_icon($ssvc, false);
+ echo get_service_control_links($ssvc, true);
+ }
} ?>
<?php if(!empty($shortcut_section) && !empty($shortcuts[$shortcut_section]['status'])): ?>
<a href="<?php echo $shortcuts[$shortcut_section]['status']; ?>" title="<?php echo gettext("Status of items on this page."); ?>"><img style="vertical-align:middle" src="/themes/<?php echo $g['theme']; ?>/images/status.png" border="0"></a>
OpenPOWER on IntegriCloud