summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--etc/inc/service-utils.inc32
-rwxr-xr-xusr/local/www/status_services.php7
-rw-r--r--usr/local/www/widgets/widgets/services_status.widget.php28
3 files changed, 33 insertions, 34 deletions
diff --git a/etc/inc/service-utils.inc b/etc/inc/service-utils.inc
index f62952c..0e987d9 100644
--- a/etc/inc/service-utils.inc
+++ b/etc/inc/service-utils.inc
@@ -408,19 +408,19 @@ function get_service_status_icon($service, $withtext = true, $smallicon = false)
$output = "";
if(get_service_status($service)) {
$statustext = gettext("Running");
- $output .= '<td class="listr"><center>' . "\n";
+ $output .= '<td class="listr" align="center">' . "\n";
$output .= "<img style=\"vertical-align:middle\" title=\"" . sprintf(gettext("%s Service is"),$service["name"]) . " {$statustext}\" src=\"/themes/" . $g["theme"] . "/images/icons/";
$output .= ($smallicon) ? "icon_pass.gif" : "icon_service_running.gif";
- $output .= "\">";
+ $output .= "\" alt=\"status\" />";
if ($withtext)
$output .= "&nbsp;&nbsp;" . $statustext;
$output .= "</td>\n";
} else {
$statustext = gettext("Stopped");
- $output .= '<td class="listbg"><center>' . "\n";
+ $output .= '<td class="listbg" align="center">' . "\n";
$output .= "<img style=\"vertical-align:middle\" title=\"" . sprintf(gettext("%s Service is"),$service["name"]) . " {$statustext}\" src=\"/themes/" . $g["theme"] . "/images/icons/";
$output .= ($smallicon) ? "icon_block.gif" : "icon_service_stopped.gif";
- $output .= "\">";
+ $output .= "\" alt=\"status\" />";
if ($withtext)
$output .= "&nbsp;&nbsp;" . "<font color=\"white\">{$statustext}</font>";
$output .= "</td>\n";
@@ -435,39 +435,39 @@ function get_service_control_links($service, $addname = false) {
if(get_service_status($service)) {
switch ($service['name']) {
case "openvpn":
- $output .= "<a href='status_services.php?mode=restartservice&service={$service['name']}&vpnmode={$service['mode']}&id={$service['vpnid']}'>";
+ $output .= "<a href='status_services.php?mode=restartservice&amp;service={$service['name']}&amp;vpnmode={$service['mode']}&amp;id={$service['vpnid']}'>";
break;
case "captiveportal":
- $output .= "<a href='status_services.php?mode=restartservice&service={$service['name']}&zone={$service['zone']}'>";
+ $output .= "<a href='status_services.php?mode=restartservice&amp;service={$service['name']}&amp;zone={$service['zone']}'>";
break;
default:
- $output .= "<a href='status_services.php?mode=restartservice&service={$service['name']}'>";
+ $output .= "<a href='status_services.php?mode=restartservice&amp;service={$service['name']}'>";
}
- $output .= "<img style=\"vertical-align:middle\" title='" . sprintf(gettext("Restart %sService"),$stitle) . "' border='0' src='./themes/".$g['theme']."/images/icons/icon_service_restart.gif'></a>\n";
+ $output .= "<img style=\"vertical-align:middle\" title='" . sprintf(gettext("Restart %sService"),$stitle) . "' border='0' src='./themes/".$g['theme']."/images/icons/icon_service_restart.gif' alt='restart' /></a>\n";
switch ($service['name']) {
case "openvpn":
- $output .= "<a href='status_services.php?mode=stopservice&service={$service['name']}&vpnmode={$service['mode']}&id={$service['vpnid']}'>";
+ $output .= "<a href='status_services.php?mode=stopservice&amp;service={$service['name']}&amp;vpnmode={$service['mode']}&amp;id={$service['vpnid']}'>";
break;
case "captiveportal":
- $output .= "<a href='status_services.php?mode=stopservice&service={$service['name']}&zone={$service['zone']}'>";
+ $output .= "<a href='status_services.php?mode=stopservice&amp;service={$service['name']}&amp;zone={$service['zone']}'>";
break;
default:
- $output .= "<a href='status_services.php?mode=stopservice&service={$service['name']}'>";
+ $output .= "<a href='status_services.php?mode=stopservice&amp;service={$service['name']}'>";
}
- $output .= "<img style=\"vertical-align:middle\" title='" . sprintf(gettext("Stop %sService"),$stitle) . "' border='0' src='./themes/".$g['theme']."/images/icons/icon_service_stop.gif'>";
+ $output .= "<img style=\"vertical-align:middle\" title='" . sprintf(gettext("Stop %sService"),$stitle) . "' border='0' src='./themes/".$g['theme']."/images/icons/icon_service_stop.gif' alt='stop' />";
$output .= "</a>";
} else {
switch ($service['name']) {
case "openvpn":
- $output .= "<a href='status_services.php?mode=startservice&service={$service['name']}&vpnmode={$service['mode']}&id={$service['vpnid']}'>";
+ $output .= "<a href='status_services.php?mode=startservice&amp;service={$service['name']}&amp;vpnmode={$service['mode']}&amp;id={$service['vpnid']}'>";
break;
case "captiveportal":
- $output .= "<a href='status_services.php?mode=startservice&service={$service['name']}&zone={$service['zone']}'>";
+ $output .= "<a href='status_services.php?mode=startservice&amp;service={$service['name']}&amp;zone={$service['zone']}'>";
break;
default:
- $output .= "<a href='status_services.php?mode=startservice&service={$service['name']}'>";
+ $output .= "<a href='status_services.php?mode=startservice&amp;service={$service['name']}'>";
}
- $output .= "<img style=\"vertical-align:middle\" title='" . sprintf(gettext("Start %sService"),$stitle) . "' border='0' src='./themes/".$g['theme']."/images/icons/icon_service_start.gif'></a>\n";
+ $output .= "<img style=\"vertical-align:middle\" title='" . sprintf(gettext("Start %sService"),$stitle) . "' border='0' src='./themes/".$g['theme']."/images/icons/icon_service_start.gif' alt='start' /></a>\n";
}
return $output;
}
diff --git a/usr/local/www/status_services.php b/usr/local/www/status_services.php
index 608804f..1bbd976 100755
--- a/usr/local/www/status_services.php
+++ b/usr/local/www/status_services.php
@@ -229,10 +229,8 @@ include("fbegin.inc");
<form action="status_services.php" method="post">
<?php if ($savemsg) print_info_box($savemsg); ?>
-<p>
-
<div id="boxarea">
-<table class="tabcont sortable" width="100%" border="0" cellpadding="0" cellspacing="0">
+<table class="tabcont sortable" width="100%" border="0" cellpadding="0" cellspacing="0" summary="status services">
<thead>
<tr>
<td class="listhdrr" align="center"><?=gettext("Service");?></td>
@@ -255,7 +253,7 @@ if (count($services) > 0) {
echo '<tr><td class="listlr" width="20%">' . $service['name'] . '</td>' . "\n";
echo '<td class="listr" width="55%">' . $service['description'] . '</td>' . "\n";
echo get_service_status_icon($service, true, true);
- echo '<td valign="middle" class="list" nowrap>';
+ echo '<td valign="middle" class="list nowrap">';
echo get_service_control_links($service);
$scut = get_shortcut_by_service_name($service['name']);
if (!empty($scut)) {
@@ -273,7 +271,6 @@ if (count($services) > 0) {
</tbody>
</table>
</div>
-</p>
</form>
<?php include("fend.inc"); ?>
</body>
diff --git a/usr/local/www/widgets/widgets/services_status.widget.php b/usr/local/www/widgets/widgets/services_status.widget.php
index 11ecfcd..d69919b 100644
--- a/usr/local/www/widgets/widgets/services_status.widget.php
+++ b/usr/local/www/widgets/widgets/services_status.widget.php
@@ -46,21 +46,21 @@ if(isset($_POST['servicestatusfilter'])) {
header("Location: ../../index.php");
}
?>
-<input type="hidden" id="services_status-config" name="services_status-config" value="">
-<div id="services_status-settings" name="services_status-settings" class="widgetconfigdiv" style="display:none;">
- <form action="/widgets/widgets/services_status.widget.php" method="post" name="iforma">
+<input type="hidden" id="services_status-config" name="services_status-config" value="" />
+<div id="services_status-settings" class="widgetconfigdiv" style="display:none;">
+ <form action="/widgets/widgets/services_status.widget.php" method="post" name="iformd">
Comma separated list of services to NOT display in the widget<br />
- <input type="text" length="30" name="servicestatusfilter" class="formfld unknown" id="servicestatusfilter" value="<?= $config['widgets']['servicestatusfilter'] ?>">
- <input id="submita" name="submita" type="submit" class="formbtn" value="Save" />
+ <input type="text" size="30" name="servicestatusfilter" class="formfld unknown" id="servicestatusfilter" value="<?= $config['widgets']['servicestatusfilter'] ?>" />
+ <input id="submitd" name="submitd" type="submit" class="formbtn" value="Save" />
</form>
</div>
-<table width="100%" border="0" cellpadding="0" cellspacing="0">
+<table width="100%" border="0" cellpadding="0" cellspacing="0" summary="services">
<tr>
- <td class="widgetsubheader"><b><center>Service</center></b></td>
- <td class="widgetsubheader"><b><center>Description</center></b></td>
- <td class="widgetsubheader"><b><center>Status</center></b></td>
- <td class="widgetsubheader">&nbsp;</td>
+ <td class="widgetsubheader" align="center"><b>Service></b></td>
+ <td class="widgetsubheader" align="center"><b>Description</b></td>
+ <td class="widgetsubheader" align="center"><b>Status</b></td>
+ <td class="widgetsubheader">&nbsp;</td>
</tr>
<?php
$skipservices = explode(",", $config['widgets']['servicestatusfilter']);
@@ -76,19 +76,21 @@ if (count($services) > 0) {
echo '<tr><td class="listlr">' . $service['name'] . '</td>' . "\n";
echo '<td class="listr">' . $service_desc[0] . '</td>' . "\n";
echo get_service_status_icon($service, false, true);
- echo '<td valign="middle" class="list" nowrap>';
+ echo '<td valign="middle" class="list nowrap">';
echo get_service_control_links($service);
echo "</td></tr>\n";
}
} else {
- echo "<tr><td colspan=\"3\"><center>" . gettext("No services found") . ".</td></tr>\n";
+ echo "<tr><td colspan=\"3\" align=\"center\">" . gettext("No services found") . ".</td></tr>\n";
}
?>
</table>
<!-- needed to display the widget settings menu -->
-<script language="javascript" type="text/javascript">
+<script type="text/javascript">
+//<![CDATA[
selectIntLink = "services_status-configure";
textlink = document.getElementById(selectIntLink);
textlink.style.display = "inline";
+//]]>
</script>
OpenPOWER on IntegriCloud