add stations

This commit is contained in:
2022-06-09 16:47:35 +02:00
parent 7bf8b8c1bf
commit af4207f66e
5 changed files with 72 additions and 22 deletions

View File

@@ -9,19 +9,29 @@
$_SESSION['select-statistics'] = $_GET['stationen'];
}
if(!isset($_SESSION['select-statistics']) || $_SESSION['select-statistics'] == "total-score") {
$session = "total-score";
} else {
$session = $_SESSION['select-statistics'];
}
echo file_get_contents("html/header.html");
?>
<body>
<div class="headline">
<?php
if($session == "total-score") {
echo "<h2>Gesamtpunkte</h2\n";
} else {
echo "<h2>" . get_station_name($con, $session)['name'] . "</h2>\n";
}
?>
</div>
<div>
<form name="switch-statistics" method="get">
<select name="stationen" id="station" onchange="this.form.submit()">
<?php
if(!isset($_SESSION['select-statistics']) || $_SESSION['select-statistics'] == "total-score") {
$session = "total-score";
} else {
$session = $_SESSION['select-statistics'];
}
load_options_stations($con, $session);
?>
</select>
@@ -36,15 +46,6 @@
?>
</div>
<div class="headline">
<?php
if($session == "total-score") {
echo "<h2>Gesamtpunkte</h2\n";
} else {
echo "<h2>" . get_station_name($con, $session)['name'] . "</h2>\n";
}
?>
</div>
<div class="table-div">
<table>
<?php