MMDVMHost-Dashboard/include/ysfgatewayinfo.php

96 lines
3.3 KiB
PHP
Raw Normal View History

2017-01-10 15:05:55 +01:00
<?php
?>
<div class="panel panel-default">
<!-- Standard-Panel-Inhalt -->
<div class="panel-heading"><?php echo _("YSFGateway-Infos"); ?><span class="pull-right clickable"><i class="glyphicon glyphicon-chevron-up"></i></span></div>
2017-03-02 16:56:46 +01:00
<div class="panel-body">
2017-01-10 15:05:55 +01:00
<!-- Tabelle -->
<table class="table">
<tr>
2018-02-11 22:59:54 +01:00
<td><span class="badge <?php
2017-01-10 15:05:55 +01:00
if (isProcessRunning("YSFGateway")) {
2018-02-11 22:59:54 +01:00
echo "badge-success";
?>"><?php echo _("YSFGateway Process is running"); ?></span></td><?php
2017-01-10 15:05:55 +01:00
} else {
2018-02-11 22:59:54 +01:00
echo "badge-danger\" title=\"YSFGateway is down!";
?>"><?php echo _("YSFGateway Process is down!"); ?></span></td><?php
2017-01-10 15:05:55 +01:00
}
?>
</tr>
</table>
2017-03-02 16:56:46 +01:00
</div>
2017-01-10 15:05:55 +01:00
</div>
<div class="panel panel-default">
<!-- Standard-Panel-Inhalt -->
<div class="panel-heading"><?php echo _("YSFReflectors reported active"); ?><span class="pull-right clickable"><i class="glyphicon glyphicon-chevron-up"></i></span></div>
2017-03-02 16:56:46 +01:00
<div class="panel-body">
2017-01-10 15:05:55 +01:00
<!-- Tabelle -->
<div class="table-responsive">
2017-01-18 12:44:11 +01:00
<table id="ysfGateways" class="table ysfGateways table-condensed table-striped table-hover">
2017-01-10 15:05:55 +01:00
<?php
if (count($activeYSFReflectors) > 0) {
?>
<thead>
<tr>
<th><?php echo _("No."); ?></th>
<th><?php echo _("Name"); ?></th>
<th><?php echo _("Description"); ?></th>
<th><?php echo _("ID"); ?></th>
<th><?php echo _("Connections"); ?></th>
2017-01-10 15:05:55 +01:00
</tr>
</thead>
<tbody>
<?php
$counter = 1;
foreach ($activeYSFReflectors as $reflector) {
echo "<tr>";
echo "<td>$counter</td>";
for ($i = 0; $i < 5; $i++) {
if ($i == 0 && defined("ENABLEYSFREFLECTORSWITCHING")) {
echo"<td><a href=\"scripts/switchysfreflector.php?reflector=$reflector[3]\" title=\"Click to connect to\">$reflector[$i]</a>";
$i++;
if ($reflector[$i] !=="") {
if (startsWith($reflector[$i],"http"))
echo ' <a target="_new" href="'.$reflector[$i].'"><img src="images/dashboard.png" /></a>';
else
echo ' <a target="_new" href="http://'.$reflector[$i].'"><img src="images/dashboard.png" /></a>';
}
echo"</td>";
} else {
if ($i == 0) {
echo"<td>$reflector[$i]";
$i++;
if ($reflector[$i] !=="") {
if (startsWith($reflector[$i],"http"))
echo ' <a target="_new" href="'.$reflector[$i].'"><img src="images/dashboard.png" /></a>';
else
echo ' <a target="_new" href="http://'.$reflector[$i].'"><img src="images/dashboard.png" /></a>';
}
echo"</td>";
} else {
echo"<td>$reflector[$i]</td>";
}
}
2017-01-10 15:05:55 +01:00
}
echo "</tr>\n";
$counter++;
}
}
?>
<tbody>
</table>
</div>
</div>
2017-03-02 16:56:46 +01:00
</div>
2017-01-10 15:05:55 +01:00
<script>
$(document).ready(function(){
var ysfGatewaysT = $('#ysfGateways').dataTable( {
"language": <?php echo DATATABLESTRANSLATION; ?>,
2017-01-10 15:05:55 +01:00
"aaSorting": [[0,'asc']]
} );
});
</script>