Skip to content
This repository was archived by the owner on Sep 13, 2024. It is now read-only.

Commit 16b2493

Browse files
authored
Merge pull request #26 from kc1awv/bootstrap4
Bootstrap 4
2 parents bf03a03 + 2153b3a commit 16b2493

File tree

10 files changed

+361
-316
lines changed

10 files changed

+361
-316
lines changed

include/allheard.php

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
<?php
22
?>
3-
<div class="panel panel-default">
4-
<!-- Standard-Panel-Inhalt -->
5-
<div class="panel-heading">Todays Heard List</div>
6-
<!-- Tabelle -->
7-
<div class="table-responsive">
3+
<div class="card">
4+
<div class="card-header">Todays Heard List</div>
5+
<div class="table-responsive">
86
<table id="allHeard" class="table table-condensed">
97
<thead>
108
<tr>
@@ -21,7 +19,7 @@
2119
$listElem = $allHeard[$i];
2220
echo"<tr>";
2321
echo"<td>$listElem[0]</td>";
24-
22+
2523
if (defined("GDPR"))
2624
echo"<td nowrap>".str_replace("0","&Oslash;",substr($listElem[1],0,3)."***")."</td>";
2725
else

include/disk.php

Lines changed: 9 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,11 @@
1-
<div class="panel panel-default">
2-
<!-- Standard-Panel-Inhalt -->
3-
<div class="panel-heading">Disk use</div>
4-
<!-- Tabelle -->
5-
<div class="table-responsive">
1+
<div class="card">
2+
<div class="card-header">Disk use</div>
3+
<div class="table-responsive">
64
<table id="diskuse" class="table table-condensed table-striped table-hover">
75

86
<thead>
97
<tr>
10-
8+
119
<th class="w10p filesystem">Filesystem</th>
1210
<th class="w20p">Mount</th>
1311
<th>Use</th>
@@ -17,7 +15,7 @@
1715
</tr>
1816
</thead>
1917
<tbody>
20-
18+
2119
<?php
2220

2321
error_reporting(E_ERROR | E_WARNING | E_PARSE);
@@ -51,7 +49,7 @@
5149
continue;
5250

5351

54-
?>
52+
?>
5553

5654
<tr>
5755
<td><?php echo $filesystem ?></td>
@@ -61,27 +59,20 @@
6159
<td><?php echo getSize($used * 1024) ?></td>
6260
<td><?php echo getSize($total * 1024) ?></td>
6361
</tr>
64-
65-
<?php
62+
63+
<?php
6664
$key++;
6765
}
6866

6967
}
7068

71-
72-
73-
7469
} catch (Exception $e) {
7570
return false;
7671
}
7772

7873
?>
7974

80-
81-
8275
</tbody>
8376
</table>
84-
</div>
77+
</div>
8578
</div>
86-
87-

include/gateways.php

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
<?php
22
?>
3-
<div class="panel panel-default">
4-
<!-- Standard-Panel-Inhalt -->
5-
<div class="panel-heading">Connected YSFGateways</div>
6-
<!-- Tabelle -->
7-
<div class="table-responsive">
3+
<div class="card">
4+
<div class="card-header">Connected YSFGateways</div>
5+
<div class="table-responsive">
86
<table id="gateways" class="table table-condensed">
97
<thead>
108
<tr>
@@ -17,10 +15,10 @@
1715
//$gateways = getConnectedGateways($logLines);
1816
$gateways = getLinkedGateways($logLines);
1917
foreach ($gateways as $gateway) {
20-
18+
2119
echo "<tr>";
2220
echo "<td>".convertTimezone($gateway['timestamp'])."</td>";
23-
21+
2422
if (defined("GDPR"))
2523
echo"<td nowrap>".str_replace("0","&Oslash;",substr($gateway['callsign'],0,3)."***")."</td>";
2624
else

include/lh.php

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
<?php
22
?>
3-
<div class="panel panel-default">
4-
<!-- Standard-Panel-Inhalt -->
5-
<div class="panel-heading">Last Heard List</div>
6-
<!-- Tabelle -->
7-
<div class="table-responsive">
3+
<div class="card">
4+
<div class="card-header">Last Heard List</div>
5+
<div class="table-responsive">
86
<table id="lh" class="table table-condensed">
97
<thead>
108
<tr>

include/oldheard.php

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
<?php
22
?>
3-
<div class="panel panel-default">
4-
<!-- Standard-Panel-Inhalt -->
5-
<div class="panel-heading">Alltime Heard List</div>
6-
<!-- Tabelle -->
7-
<div class="table-responsive">
3+
<div class="card">
4+
<div class="card-header">Alltime Heard List</div>
5+
<div class="table-responsive">
86
<table id="oldallHeard" class="table table-condensed">
97
<thead>
108
<tr>
@@ -20,7 +18,7 @@
2018
$listElem = $oldallHeard[$i];
2119
echo"<tr>";
2220
echo"<td>$listElem[0]</td>";
23-
21+
2422
if (defined("GDPR"))
2523
echo"<td nowrap>".str_replace("0","&Oslash;",substr($listElem[1],0,3)."***")."</td>";
2624
else

include/sysinfo.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,9 +96,9 @@ function makeLayer(id,L,T,W,H,bgColor,visible,zIndex) {
9696
$idletime = format_time((substr($output,strpos($output," ")))/$cpucores);
9797

9898
?>
99-
<div class="panel panel-default">
99+
<div class="card">
100100
<!-- Standard-Panel-Inhalt -->
101-
<div class="panel-heading">System Info</div>
101+
<div class="card-header">System Info</div>
102102
<!-- Tabelle -->
103103
<div class="table-responsive">
104104
<table id="sysinfo" class="table table-condensed">

include/txinfo.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
<div class="panel panel-default">
1+
<div class="card">
22
<!-- Standard-Panel-Inhalt -->
3-
<div class="panel-heading">Currently TXing</div>
3+
<div class="card-header">Currently TXing</div>
44
<!-- Tabelle -->
5-
<div class="table-responsive">
5+
<div class="table-responsive">
66
<table id="currtx" class="table table-condensed table-striped table-hover">
77
<thead>
88
<tr>
@@ -16,7 +16,7 @@
1616
<tbody id="txline">
1717
</tbody>
1818
</table>
19-
</div>
19+
</div>
2020
</div>
2121
<script>
2222
function doXMLHTTPRequest(scriptname, elem) {

index.php

Lines changed: 113 additions & 83 deletions
Original file line numberDiff line numberDiff line change
@@ -1,83 +1,113 @@
1-
<?php
2-
$time = microtime();
3-
$time = explode(' ', $time);
4-
$time = $time[1] + $time[0];
5-
$start = $time;
6-
header("Cache-Control: no-cache, must-revalidate");
7-
header("Expires: Sat, 26 Jul 1997 05:00:00 GMT");
8-
// do not touch this includes!!! Never ever!!!
9-
include "config/config.php";
10-
include "include/tools.php";
11-
include "include/functions.php";
12-
include "include/init.php";
13-
include "version.php";
14-
?>
15-
<!doctype html>
16-
<html lang="en">
17-
<head>
18-
<meta charset="utf-8">
19-
<!--<meta name="viewport" content="width=device-width, initial-scale=1.0">
20-
-->
21-
<meta name="viewport" content="width=device-width, initial-scale=0.6,maximum-scale=1, user-scalable=yes">
22-
<meta http-equiv="refresh" content="<?php echo REFRESHAFTER?>">
23-
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.3/jquery.min.js"></script>
24-
<!-- Das neueste kompilierte und minimierte CSS -->
25-
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css">
26-
<!-- Optionales Theme -->
27-
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap-theme.min.css">
28-
<!-- Das neueste kompilierte und minimierte JavaScript -->
29-
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>
30-
<!-- Datatables -->
31-
<link rel="stylesheet" href="https://cdn.datatables.net/1.10.12/css/jquery.dataTables.min.css">
32-
<script type="text/javascript" src="https://cdn.datatables.net/1.10.12/js/jquery.dataTables.min.js"></script>
33-
<style>
34-
h4 {
35-
display: inline
36-
}
37-
body{
38-
padding: 10px;
39-
}
40-
</style>
41-
<title><?php echo getConfigItem("Info", "Name", $configs); ?> - YSFReflector-Dashboard by DG9VH</title>
42-
</head>
43-
<body>
44-
<div class="page-header" style="position:relative;">
45-
<h1><small>YSFReflector-Dashboard by DG9VH for Reflector:</small> <?php echo getConfigItem("Info", "Name", $configs); ?> / <?php echo getConfigItem("Info", "Description", $configs); ?></h1>
46-
<h4>YSFReflector by G4KLX Version:
47-
<?php echo getYSFReflectorVersion(); ?></h4>
48-
<?php
49-
if (LOGO !== "") {
50-
?>
51-
<div id="Logo" style="position:absolute;top:-43px;right:10px;"><img src="<?php echo LOGO ?>" width="250px" style="width:250px; border-radius:10px;box-shadow:2px 2px 2px #808080; padding:1px;background:#FFFFFF;border:1px solid #808080;" border="0" hspace="10" vspace="10" align="absmiddle"></div>
52-
<?php
53-
}
54-
?>
55-
</div>
56-
<?php
57-
checkSetup();
58-
// Here you can feel free to disable info-sections by commenting out with // before include
59-
include "include/txinfo.php";
60-
include "include/sysinfo.php";
61-
include "include/disk.php";
62-
include "include/gateways.php";
63-
include "include/lh.php";
64-
include "include/allheard.php";
65-
if (defined("SHOWOLDMHEARD")) {
66-
include "include/oldheard.php";
67-
}
68-
?>
69-
<div class="panel panel-info">
70-
<?php
71-
$lastReload = new DateTime();
72-
$lastReload->setTimezone(new DateTimeZone(TIMEZONE));
73-
echo "YSFReflector-Dashboard V ".VERSION." | Last Reload ".$lastReload->format('Y-m-d, H:i:s')." (".TIMEZONE.")";
74-
$time = microtime();
75-
$time = explode(' ', $time);
76-
$time = $time[1] + $time[0];
77-
$finish = $time;
78-
$total_time = round(($finish - $start), 4);
79-
echo '<!--Page generated in '.$total_time.' seconds.-->';
80-
?> | get your own at: <a href="https://github.com/dg9vh/YSFReflector-Dashboard">https://github.com/dg9vh/YSFReflector-Dashboard</a>
81-
</div>
82-
</body>
83-
</html>
1+
<?php
2+
$time = microtime();
3+
$time = explode(' ', $time);
4+
$time = $time[1] + $time[0];
5+
$start = $time;
6+
// do not touch this includes!!! Never ever!!!
7+
include "config/config.php";
8+
include "include/tools.php";
9+
include "include/functions.php";
10+
include "include/init.php";
11+
include "version.php";
12+
?>
13+
14+
<!DOCTYPE html>
15+
<html lang="en">
16+
17+
<head>
18+
19+
<meta charset="utf-8">
20+
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
21+
<meta name="description" content="YSF-Reflector Dashboard by DG9VH">
22+
<meta name="author" content="DG9VH, KC1AWV">
23+
<meta http-equiv="refresh" content="<?php echo REFRESHAFTER?>">
24+
25+
<title><?php echo getConfigItem("Info", "Name", $configs); ?> - YSFReflector-Dashboard by DG9VH</title>
26+
27+
<!-- Bootstrap core CSS -->
28+
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
29+
30+
</head>
31+
32+
<body>
33+
34+
<!-- Navigation -->
35+
<nav class="navbar navbar-expand-lg navbar-dark bg-dark static-top">
36+
<div class="container-fluid">
37+
<span class="float:left">
38+
<a class="navbar-brand" href="#">YSFReflector-Dashboard by DG9VH for Reflector: <?php echo getConfigItem("Info", "Name", $configs); ?> / <?php echo getConfigItem("Info", "Description", $configs); ?></a>
39+
</span>
40+
<span class="navbar-brand float:right">
41+
YSFReflector by G4KLX Version: <?php echo getYSFReflectorVersion(); ?>
42+
</span>
43+
</div>
44+
</nav>
45+
46+
<!-- Page Content -->
47+
<div class="container-fluid">
48+
<?php
49+
checkSetup();
50+
?>
51+
<div class="row">
52+
<div class="col-10">
53+
<?php
54+
include "include/txinfo.php";
55+
?>
56+
</div>
57+
<?php if (LOGO !== "") { ?>
58+
<div id="Logo" class="col-2">
59+
<img src="<?php echo LOGO ?>" width="250px" style="width:250px; border-radius:10px;box-shadow:2px 2px 2px #808080; padding:1px;background:#FFFFFF;border:1px solid #808080;" border="0" hspace="10" vspace="10" align="justify-content-center">
60+
</div>
61+
<?php } else { ?>
62+
<div id="Logo" class="col-2">
63+
<h3 class="text-center">YSF-Reflector<br />Dashboard</h3>
64+
</div>
65+
<?php } ?>
66+
</div>
67+
</div>
68+
69+
<div class="row">
70+
<div class="col">
71+
<?php
72+
include "include/sysinfo.php";
73+
?>
74+
</div>
75+
<div class="col">
76+
<?php
77+
include "include/disk.php";
78+
?>
79+
</div>
80+
</div>
81+
<?php
82+
include "include/gateways.php";
83+
include "include/lh.php";
84+
include "include/allheard.php";
85+
if (defined("SHOWOLDMHEARD")) {
86+
include "include/oldheard.php";
87+
}
88+
?>
89+
</div>
90+
91+
<div class="card">
92+
<div class="card-body">
93+
<?php
94+
$lastReload = new DateTime();
95+
$lastReload->setTimezone(new DateTimeZone(TIMEZONE));
96+
echo "YSFReflector-Dashboard V ".VERSION." | Last Reload ".$lastReload->format('Y-m-d, H:i:s')." (".TIMEZONE.")";
97+
$time = microtime();
98+
$time = explode(' ', $time);
99+
$time = $time[1] + $time[0];
100+
$finish = $time;
101+
$total_time = round(($finish - $start), 4);
102+
echo '<!--Page generated in '.$total_time.' seconds.-->';
103+
?> | get your own at: <a href="https://github.com/dg9vh/YSFReflector-Dashboard">https://github.com/dg9vh/YSFReflector-Dashboard</a>
104+
</div>
105+
</div>
106+
107+
<!-- Bootstrap core JavaScript -->
108+
<script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
109+
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js" integrity="sha384-UO2eT0CpHqdSJQ6hJty5KVphtPhzWj9WO1clHTMGa3JDZwrnQq4sF86dIHNDz0W1" crossorigin="anonymous"></script>
110+
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js" integrity="sha384-JjSmVgyd0p3pXB1rRibZUAYoIIy6OrQ6VrjIEaFf/nJGzIxFDsf4x0xIM+B07jRM" crossorigin="anonymous"></script>
111+
</body>
112+
113+
</html>

0 commit comments

Comments
 (0)