Compare commits
4 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
efaba0abbe | ||
|
e2307b881d | ||
|
713e83e89e | ||
|
1a66405e4a |
108
README.md
108
README.md
@ -13,63 +13,63 @@ Dort wird die vereinfachte Version exportiert.
|
||||
|
||||
## Direktlinks
|
||||
|
||||
* [Aachen (Städteregion)](https://unfallkarte.hpadm.de/aachen)
|
||||
* [Bielefeld (kreisfreie Stadt)](https://unfallkarte.hpadm.de/bielefeld)
|
||||
* [Bochum (kreisfreie Stadt)](https://unfallkarte.hpadm.de/bochum)
|
||||
* [Bonn (kreisfreie Stadt)](https://unfallkarte.hpadm.de/bonn)
|
||||
* [Borken](https://unfallkarte.hpadm.de/borken)
|
||||
* [Bottrop (kreisfreie Stadt)](https://unfallkarte.hpadm.de/bottrop)
|
||||
* [Coesfeld](https://unfallkarte.hpadm.de/coesfeld)
|
||||
* [Dortmund (kreisfreie Stadt)](https://unfallkarte.hpadm.de/dortmund)
|
||||
* [Duisburg (kreisfreie Stadt)](https://unfallkarte.hpadm.de/duisburg)
|
||||
* [Düren](https://unfallkarte.hpadm.de/dueren)
|
||||
* [Düsseldorf (kreisfreie Stadt)](https://unfallkarte.hpadm.de/duesseldorf)
|
||||
* [Ennepe-Ruhr-Kreis](https://unfallkarte.hpadm.de/erk)
|
||||
* [Essen (kreisfreie Stadt)](https://unfallkarte.hpadm.de/essen)
|
||||
* [Euskirchen](https://unfallkarte.hpadm.de/euskrichen)
|
||||
* [Gelsenkirchen (kreisfreie Stadt)](https://unfallkarte.hpadm.de/gelsenkirchen)
|
||||
* [Gütersloh](https://unfallkarte.hpadm.de/guetersloh)
|
||||
* [Hagen (kreisfreie Stadt)](https://unfallkarte.hpadm.de/hagen)
|
||||
* [Hamm (kreisfreie Stadt)](https://unfallkarte.hpadm.de/hamm)
|
||||
* [Heinsberg](https://unfallkarte.hpadm.de/heinsberg)
|
||||
* [Herford](https://unfallkarte.hpadm.de/herford)
|
||||
* [Herne (kreisfreie Stadt)](https://unfallkarte.hpadm.de/herne)
|
||||
* [Hochsauerlandkreis](https://unfallkarte.hpadm.de/hochsauerlandkreis)
|
||||
* [Höxter](https://unfallkarte.hpadm.de/hoexter)
|
||||
* [Kleve](https://unfallkarte.hpadm.de/kleve)
|
||||
* [Köln (kreisfreie Stadt)](https://unfallkarte.hpadm.de/koeln)
|
||||
* [Krefeld (kreisfreie Stadt)](https://unfallkarte.hpadm.de/krefeld)
|
||||
* [Leverkusen (kreisfreie Stadt)](https://unfallkarte.hpadm.de/leverkusen)
|
||||
* [Lippe](https://unfallkarte.hpadm.de/lippe)
|
||||
* [Märkischer Kreis](https://unfallkarte.hpadm.de/maerkischerkreis)
|
||||
* [Mettmann](https://unfallkarte.hpadm.de/mettmann)
|
||||
* [Minden-Lübbecke](https://unfallkarte.hpadm.de/minden-luebbecke)
|
||||
* [Mönchengladbach (kreisfreie Stadt)](https://unfallkarte.hpadm.de/moenchengladbach)
|
||||
* [Mülheim an der Ruhr (kreisfreie Stadt)](https://unfallkarte.hpadm.de/muelheim)
|
||||
* [Münster (kreisfreie Stadt)](https://unfallkarte.hpadm.de/muenster)
|
||||
* [Oberbergischer Kreis](https://unfallkarte.hpadm.de/oberbergischerkreis)
|
||||
* [Oberhausen (kreisfreie Stadt)](https://unfallkarte.hpadm.de/oberhausen)
|
||||
* [Olpe](https://unfallkarte.hpadm.de/olpe)
|
||||
* [Paderborn](https://unfallkarte.hpadm.de/paderborn)
|
||||
* [Recklinghausen](https://unfallkarte.hpadm.de/recklinghausen)
|
||||
* [Remscheid (kreisfreie Stadt)](https://unfallkarte.hpadm.de/remscheid)
|
||||
* [Rhein-Erft-Kreis](https://unfallkarte.hpadm.de/rek)
|
||||
* [Rhein-Kreis Neuss](https://unfallkarte.hpadm.de/neuss)
|
||||
* [Rhein-Sieg-Kreis](https://unfallkarte.hpadm.de/rsk)
|
||||
* [Rheinisch-Bergischer Kreis](https://unfallkarte.hpadm.de/rbk)
|
||||
* [Siegen-Wittgenstein](https://unfallkarte.hpadm.de/siegen-wittgenstein)
|
||||
* [Soest](https://unfallkarte.hpadm.de/soest)
|
||||
* [Solingen (kreisfreie Stadt)](https://unfallkarte.hpadm.de/solingen)
|
||||
* [Steinfurt](https://unfallkarte.hpadm.de/steinfurt)
|
||||
* [Unna](https://unfallkarte.hpadm.de/unna)
|
||||
* [Viersen](https://unfallkarte.hpadm.de/viersen)
|
||||
* [Warendorf](https://unfallkarte.hpadm.de/warendorf)
|
||||
* [Wesel](https://unfallkarte.hpadm.de/wesel)
|
||||
* [Wuppertal (kreisfreie Stadt)](https://unfallkarte.hpadm.de/wuppertal)
|
||||
* [Aachen (Städteregion)](https://unfallkarte.adfc-hamm.de/aachen)
|
||||
* [Bielefeld (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/bielefeld)
|
||||
* [Bochum (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/bochum)
|
||||
* [Bonn (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/bonn)
|
||||
* [Borken](https://unfallkarte.adfc-hamm.de/borken)
|
||||
* [Bottrop (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/bottrop)
|
||||
* [Coesfeld](https://unfallkarte.adfc-hamm.de/coesfeld)
|
||||
* [Dortmund (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/dortmund)
|
||||
* [Duisburg (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/duisburg)
|
||||
* [Düren](https://unfallkarte.adfc-hamm.de/dueren)
|
||||
* [Düsseldorf (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/duesseldorf)
|
||||
* [Ennepe-Ruhr-Kreis](https://unfallkarte.adfc-hamm.de/erk)
|
||||
* [Essen (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/essen)
|
||||
* [Euskirchen](https://unfallkarte.adfc-hamm.de/euskrichen)
|
||||
* [Gelsenkirchen (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/gelsenkirchen)
|
||||
* [Gütersloh](https://unfallkarte.adfc-hamm.de/guetersloh)
|
||||
* [Hagen (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/hagen)
|
||||
* [Hamm (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/hamm)
|
||||
* [Heinsberg](https://unfallkarte.adfc-hamm.de/heinsberg)
|
||||
* [Herford](https://unfallkarte.adfc-hamm.de/herford)
|
||||
* [Herne (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/herne)
|
||||
* [Hochsauerlandkreis](https://unfallkarte.adfc-hamm.de/hochsauerlandkreis)
|
||||
* [Höxter](https://unfallkarte.adfc-hamm.de/hoexter)
|
||||
* [Kleve](https://unfallkarte.adfc-hamm.de/kleve)
|
||||
* [Köln (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/koeln)
|
||||
* [Krefeld (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/krefeld)
|
||||
* [Leverkusen (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/leverkusen)
|
||||
* [Lippe](https://unfallkarte.adfc-hamm.de/lippe)
|
||||
* [Märkischer Kreis](https://unfallkarte.adfc-hamm.de/maerkischerkreis)
|
||||
* [Mettmann](https://unfallkarte.adfc-hamm.de/mettmann)
|
||||
* [Minden-Lübbecke](https://unfallkarte.adfc-hamm.de/minden-luebbecke)
|
||||
* [Mönchengladbach (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/moenchengladbach)
|
||||
* [Mülheim an der Ruhr (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/muelheim)
|
||||
* [Münster (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/muenster)
|
||||
* [Oberbergischer Kreis](https://unfallkarte.adfc-hamm.de/oberbergischerkreis)
|
||||
* [Oberhausen (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/oberhausen)
|
||||
* [Olpe](https://unfallkarte.adfc-hamm.de/olpe)
|
||||
* [Paderborn](https://unfallkarte.adfc-hamm.de/paderborn)
|
||||
* [Recklinghausen](https://unfallkarte.adfc-hamm.de/recklinghausen)
|
||||
* [Remscheid (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/remscheid)
|
||||
* [Rhein-Erft-Kreis](https://unfallkarte.adfc-hamm.de/rek)
|
||||
* [Rhein-Kreis Neuss](https://unfallkarte.adfc-hamm.de/neuss)
|
||||
* [Rhein-Sieg-Kreis](https://unfallkarte.adfc-hamm.de/rsk)
|
||||
* [Rheinisch-Bergischer Kreis](https://unfallkarte.adfc-hamm.de/rbk)
|
||||
* [Siegen-Wittgenstein](https://unfallkarte.adfc-hamm.de/siegen-wittgenstein)
|
||||
* [Soest](https://unfallkarte.adfc-hamm.de/soest)
|
||||
* [Solingen (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/solingen)
|
||||
* [Steinfurt](https://unfallkarte.adfc-hamm.de/steinfurt)
|
||||
* [Unna](https://unfallkarte.adfc-hamm.de/unna)
|
||||
* [Viersen](https://unfallkarte.adfc-hamm.de/viersen)
|
||||
* [Warendorf](https://unfallkarte.adfc-hamm.de/warendorf)
|
||||
* [Wesel](https://unfallkarte.adfc-hamm.de/wesel)
|
||||
* [Wuppertal (kreisfreie Stadt)](https://unfallkarte.adfc-hamm.de/wuppertal)
|
||||
|
||||
## Statistische Auswertungen
|
||||
|
||||
* https://radwege-hamm.de/dokuwiki/doku.php?id=unfallstatistik_nrw
|
||||
* https://wiki.radwege-hamm.de/doku.php?id=unfallstatistik_nrw
|
||||
|
||||
## Javascript-Bibliotheken
|
||||
|
||||
|
38
index.php
38
index.php
@ -30,12 +30,6 @@
|
||||
<link rel="stylesheet" href="css/leaflet.css" />
|
||||
<link rel="stylesheet" href="css/leaflet.awesome-markers.css" />
|
||||
<link rel="stylesheet" href="css/style.css" />
|
||||
|
||||
|
||||
<link rel="stylesheet" href="vendor/Leaflet.markercluster/dist/MarkerCluster.css" />
|
||||
<link rel="stylesheet" href="vendor/Leaflet.markercluster/dist/MarkerCluster.Default.css" />
|
||||
<script src="vendor/Leaflet.markercluster/dist/leaflet.markercluster-src.js"></script>
|
||||
|
||||
<title><?= $strTitle ?></title>
|
||||
</head>
|
||||
|
||||
@ -137,8 +131,6 @@
|
||||
<!-- row -->
|
||||
</div>
|
||||
<!-- container-fluid -->
|
||||
|
||||
|
||||
<script>
|
||||
// Map ----------------------------------------------------------------------
|
||||
var mymap = L.map('mapid').setView([<?=$numInfoLat ?>, <?=$numInfoLng ?>], <?=$numZoom ?>);
|
||||
@ -179,6 +171,7 @@
|
||||
}
|
||||
|
||||
//Hamm-Layer - todo invers area ---------------------------------------
|
||||
|
||||
var myStyle = {
|
||||
"color": "grey",
|
||||
"fillColor": "lightblue",
|
||||
@ -192,32 +185,6 @@
|
||||
});
|
||||
districtLayer.addTo(mymap);
|
||||
|
||||
|
||||
|
||||
|
||||
var geoJsonData = {
|
||||
"type": "FeatureCollection",
|
||||
"features": [
|
||||
{ "type": "Feature", "id":"1", "properties": { "address": "2" }, "geometry": { "type": "Point", "coordinates": [51.6792,7.77693] } },
|
||||
{ "type": "Feature", "id":"2", "properties": { "address": "151" }, "geometry": { "type": "Point", "coordinates": [51.6787,7.77699] } },
|
||||
{ "type": "Feature", "id":"3", "properties": { "address": "21" }, "geometry": { "type": "Point", "coordinates": [51.6777,7.77690] } },
|
||||
{ "type": "Feature", "id":"4", "properties": { "address": "14" }, "geometry": { "type": "Point", "coordinates": [51.6798,7.77692] } },
|
||||
{ "type": "Feature", "id":"5", "properties": { "address": "38B" }, "geometry": { "type": "Point", "coordinates": [51.6800,7.77700] } },
|
||||
{ "type": "Feature", "id":"6", "properties": { "address": "38" }, "geometry": { "type": "Point", "coordinates": [51.6747,7.77683] } }
|
||||
]
|
||||
};
|
||||
var markers = L.markerClusterGroup();
|
||||
|
||||
var geoJsonLayer = L.geoJson(geoJsonData, {
|
||||
onEachFeature: function (feature, layer) {
|
||||
layer.bindPopup(feature.properties.address);
|
||||
}
|
||||
});
|
||||
markers.addLayer(geoJsonLayer);
|
||||
|
||||
//mymap.addLayer(markers);
|
||||
// mymap.fitBounds(markers.getBounds());
|
||||
|
||||
// Marker from database -------------------------------------------------------
|
||||
|
||||
var marker = [];
|
||||
@ -233,6 +200,8 @@
|
||||
// Info-Marker für Start --------------------------------------------------------
|
||||
|
||||
var marker2 = L.marker([<?=$numInfoLat?>, <?=$numInfoLng?>], { icon: infoMarker }).addTo(mymap);
|
||||
|
||||
|
||||
<?php
|
||||
echo "marker2.bindPopup('".$strIntro."');";
|
||||
if ($numVehicle==0) {
|
||||
@ -241,6 +210,7 @@
|
||||
?>
|
||||
|
||||
|
||||
|
||||
// Hide and show marker form checkbox ----------------------------------------
|
||||
|
||||
$('.check').click(function() {
|
||||
|
@ -63,7 +63,7 @@
|
||||
<div class="col-5">
|
||||
<h4>Unfallverlauf von <?=$numLatestYear?> bis <?=$numStartYear?></h4>
|
||||
<table class='table table-sm'>
|
||||
<tr><th></th><th>2023</th><th>2022</th><th>2021</th><th>2020</th><th>2019</th></tr>
|
||||
<tr><th></th><th>2024</th><th>2023</th><th>2022</th><th>2021</th><th>2020</th><th>2019</th></tr>
|
||||
<tr><td><?= $arrCategory[1]?></td><?= get_row($resultVerlauf,1) ?></tr>
|
||||
<tr><td><?= $arrCategory[2]?></td><?= get_row($resultVerlauf,2) ?></tr>
|
||||
<tr><td><?= $arrCategory[3]?></td><?= get_row($resultVerlauf,3) ?></tr>
|
||||
|
@ -14,6 +14,15 @@
|
||||
<style>
|
||||
.rechts {text-align:right;background-color:#eee;}
|
||||
.l {border-left: 1px solid black; }
|
||||
/* Sehr kleine Schrift für Tabelle */
|
||||
#unfallzahlen {
|
||||
font-size: 11px;
|
||||
}
|
||||
|
||||
/* Optional: kleinere Schrift auch für Paginierung, Filter, usw. */
|
||||
.dataTables_wrapper {
|
||||
font-size: 11px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
@ -26,20 +35,20 @@
|
||||
<table id="unfallzahlen" class="display">
|
||||
<thead>
|
||||
<tr><th></th>
|
||||
<th colspan="4">Fahrradunfälle</th>
|
||||
<th colspan="4">Todesfälle</th>
|
||||
<th colspan="4">Schwerverletzte</th>
|
||||
<th colspan="4">Leichtverletzte</th>
|
||||
<th colspan="6">Fahrradunfälle</th>
|
||||
<th colspan="6">Todesfälle</th>
|
||||
<th colspan="6">Schwerverletzte</th>
|
||||
<th colspan="6">Leichtverletzte</th>
|
||||
<th class='l'>Fäche</th>
|
||||
<th>Einw.</th>
|
||||
<th>Quote</th>
|
||||
|
||||
</tr>
|
||||
<tr><th>Name</th>
|
||||
<th class='l'>2022</th><th>2021</th><th>2020</th><th>2019</th>
|
||||
<th class='l'>2022</th><th>2021</th><th>2020</th><th>2019</th>
|
||||
<th class='l'>2022</th><th>2021</th><th>2020</th><th>2019</th>
|
||||
<th class='l'>2022</th><th>2021</th><th>2020</th><th>2019</th>
|
||||
<th class='l'>2024</th><th>2023</th><th>2022</th><th>2021</th><th>2020</th><th>2019</th>
|
||||
<th class='l'>2024</th><th>2023</th><th>2022</th><th>2021</th><th>2020</th><th>2019</th>
|
||||
<th class='l'>2024</th><th>2023</th><th>2022</th><th>2021</th><th>2020</th><th>2019</th>
|
||||
<th class='l'>2024</th><th>2023</th><th>2022</th><th>2021</th><th>2020</th><th>2019</th>
|
||||
<th class='l' colspan="2">in Tausend</th><th></th>
|
||||
</tr>
|
||||
</thead>
|
||||
@ -49,27 +58,36 @@
|
||||
require("../config.php");
|
||||
|
||||
$strSQL="SELECT d.Name as Gemeinde,
|
||||
SUM(UJAHR=2024) as Jahr_2024,
|
||||
SUM(UJAHR=2023) as Jahr_2023,
|
||||
SUM(UJAHR=2022) as Jahr_2022,
|
||||
SUM(UJAHR=2021) as Jahr_2021,
|
||||
SUM(UJAHR=2020) as Jahr_2020,
|
||||
SUM(UJAHR=2019) as Jahr_2019,
|
||||
|
||||
SUM(UJAHR=2024 AND UKATEGORIE=1) as Tode_2024,
|
||||
SUM(UJAHR=2023 AND UKATEGORIE=1) as Tode_2023,
|
||||
SUM(UJAHR=2022 AND UKATEGORIE=1) as Tode_2022,
|
||||
SUM(UJAHR=2021 AND UKATEGORIE=1) as Tode_2021,
|
||||
SUM(UJAHR=2020 AND UKATEGORIE=1) as Tode_2020,
|
||||
SUM(UJAHR=2019 AND UKATEGORIE=1) as Tode_2019,
|
||||
|
||||
SUM(UJAHR=2024 AND UKATEGORIE=2) as Schwerverletzt_2024,
|
||||
SUM(UJAHR=2023 AND UKATEGORIE=2) as Schwerverletzt_2023,
|
||||
SUM(UJAHR=2022 AND UKATEGORIE=2) as Schwerverletzt_2022,
|
||||
SUM(UJAHR=2021 AND UKATEGORIE=2) as Schwerverletzt_2021,
|
||||
SUM(UJAHR=2020 AND UKATEGORIE=2) as Schwerverletzt_2020,
|
||||
SUM(UJAHR=2019 AND UKATEGORIE=2) as Schwerverletzt_2019,
|
||||
|
||||
|
||||
SUM(UJAHR=2024 AND UKATEGORIE=3) as Leichtverletzt_2024,
|
||||
SUM(UJAHR=2023 AND UKATEGORIE=3) as Leichtverletzt_2023,
|
||||
SUM(UJAHR=2022 AND UKATEGORIE=3) as Leichtverletzt_2022,
|
||||
SUM(UJAHR=2021 AND UKATEGORIE=3) as Leichtverletzt_2021,
|
||||
SUM(UJAHR=2020 AND UKATEGORIE=3) as Leichtverletzt_2020,
|
||||
SUM(UJAHR=2019 AND UKATEGORIE=3) as Leichtverletzt_2019,
|
||||
Flaeche, Einwohner,
|
||||
SUM(UJAHR=2022)/d.Einwohner*1000 as Quote_2022,
|
||||
SUM(UJAHR=2024)/d.Einwohner*1000 as Quote_2024,
|
||||
d.ULAND,
|
||||
d.UREGBEZ,
|
||||
d.UKREIS,
|
||||
@ -78,7 +96,7 @@ $strSQL="SELECT d.Name as Gemeinde,
|
||||
WHERE IstRad=1
|
||||
AND d.ULAND=s.ULAND AND d.UREGBEZ=s.UREGBEZ AND d.UKREIS=s.UKREIS AND d.UGEMEINDE=s.UGEMEINDE
|
||||
GROUP BY s.ULAND, s.UREGBEZ, s.UKREIS,s.UGEMEINDE
|
||||
ORDER BY Quote_2022 DESC
|
||||
ORDER BY Quote_2024 DESC
|
||||
";
|
||||
// --- ORDER BY s.ULAND, s.UREGBEZ, s.UKREIS,s.UGEMEINDE
|
||||
|
||||
@ -87,25 +105,33 @@ $result=$db->query($strSQL);
|
||||
while ($row = $result->fetch(PDO::FETCH_ASSOC)) {
|
||||
echo "<tr>";
|
||||
echo "<td><a href='gemeinde_details.php?regbez=".$row['UREGBEZ']."&kreis=".$row['UKREIS']."&gemeinde=".$row['UGEMEINDE']."'>".$row['Gemeinde']."</a></td>";
|
||||
echo "<td class='l'>".$row['Jahr_2022']."</td>";
|
||||
echo "<td class='l'>".$row['Jahr_2024']."</td>";
|
||||
echo "<td>".$row['Jahr_2023']."</td>";
|
||||
echo "<td>".$row['Jahr_2022']."</td>";
|
||||
echo "<td>".$row['Jahr_2021']."</td>";
|
||||
echo "<td>".$row['Jahr_2020']."</td>";
|
||||
echo "<td>".$row['Jahr_2019']."</td>";
|
||||
echo "<td class='l'>".$row['Tode_2022']."</td>";
|
||||
echo "<td class='l'>".$row['Tode_2024']."</td>";
|
||||
echo "<td>".$row['Tode_2023']."</td>";
|
||||
echo "<td>".$row['Tode_2022']."</td>";
|
||||
echo "<td>".$row['Tode_2021']."</td>";
|
||||
echo "<td>".$row['Tode_2020']."</td>";
|
||||
echo "<td>".$row['Tode_2019']."</td>";
|
||||
echo "<td class='l'>".$row['Schwerverletzt_2022']."</td>";
|
||||
echo "<td class='l'>".$row['Schwerverletzt_2024']."</td>";
|
||||
echo "<td>".$row['Schwerverletzt_2023']."</td>";
|
||||
echo "<td>".$row['Schwerverletzt_2022']."</td>";
|
||||
echo "<td>".$row['Schwerverletzt_2021']."</td>";
|
||||
echo "<td>".$row['Schwerverletzt_2020']."</td>";
|
||||
echo "<td>".$row['Schwerverletzt_2019']."</td>";
|
||||
echo "<td class='l'>".$row['Leichtverletzt_2022']."</td>";
|
||||
echo "<td class='l'>".$row['Leichtverletzt_2024']."</td>";
|
||||
echo "<td>".$row['Leichtverletzt_2023']."</td>";
|
||||
echo "<td>".$row['Leichtverletzt_2022']."</td>";
|
||||
echo "<td>".$row['Leichtverletzt_2021']."</td>";
|
||||
echo "<td>".$row['Leichtverletzt_2020']."</td>";
|
||||
echo "<td>".$row['Leichtverletzt_2019']."</td>";
|
||||
echo "<td class='rechts l'>".$row['Flaeche']."</td>";
|
||||
echo "<td class='rechts'>".round($row['Einwohner']/1000,1)."</td>";
|
||||
echo "<td class='rechts'>".round($row['Quote_2022'],2)."</td>";
|
||||
echo "<td class='rechts'>".round($row['Quote_2024'],2)."</td>";
|
||||
echo "</tr>\n";
|
||||
}
|
||||
?>
|
||||
|
@ -155,7 +155,7 @@ Highcharts.chart('c_unfallverlauf', {
|
||||
align: 'center'
|
||||
},
|
||||
xAxis: {
|
||||
categories: ['2023','2022','2021','2020','2019']
|
||||
categories: ['2024','2023','2022','2021','2020','2019']
|
||||
},
|
||||
yAxis: {
|
||||
min: 0,
|
||||
|
@ -39,13 +39,13 @@
|
||||
<a href="https://www.govdata.de/dl-de/by-2-0" target="_blanc">Datenlizenz Deutschland – Namensnennung – Version 2.0</a></p>
|
||||
|
||||
|
||||
<p>
|
||||
<div style="border:2px solid red; background-color: lightgray; padding:4px;">
|
||||
Die im Unfallatlas visualisierten Unfalldaten stammen aus der Statistik der Straßenverkehrsunfälle,
|
||||
die auf den Meldungen der Polizei basiert. Falls die Geo-Koordinaten der Unfallmeldung nicht einer
|
||||
Straße eindeutig zugeordnet werden können (Abgleich mit den Straßengeometrien der amtlichen Vermessungsverwaltung),
|
||||
werden sie nicht im Unfallatlas abgebildet. Die Zuordnungsquoten der Unfallkoordinaten
|
||||
im Unfallatlas liegen bei mehr als 90 Prozent.
|
||||
</p>
|
||||
</div>
|
||||
<p> </p>
|
||||
<ul class="list-group" style="width:40em;">
|
||||
<li class="list-group-item"><a href="nrw_details.php"><strong>Landeswerte NRW</strong></a></li>
|
||||
|
@ -14,7 +14,18 @@
|
||||
<style>
|
||||
.rechts {text-align:right;}
|
||||
.l {border-left: 1px solid black; }
|
||||
|
||||
/* Sehr kleine Schrift für Tabelle */
|
||||
#unfallzahlen {
|
||||
font-size: 11px;
|
||||
}
|
||||
|
||||
/* Optional: kleinere Schrift auch für Paginierung, Filter, usw. */
|
||||
.dataTables_wrapper {
|
||||
font-size: 11px;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@ -35,10 +46,10 @@
|
||||
</tr>
|
||||
|
||||
<tr><th>Kreis</th>
|
||||
<th class="l">2023</th><th>2022</th><th>2021</th><th>2020</th><th>2019</th>
|
||||
<th class="l">2023</th><th>2022</th><th>2021</th><th>2020</th><th>2019</th>
|
||||
<th class="l">2023</th><th>2022</th><th>2021</th><th>2020</th><th>2019</th>
|
||||
<th class="l">2023</th><th>2022</th><th>2021</th><th>2020</th><th>2019</th>
|
||||
<th class="l">2024</th><th>2023</th><th>2022</th><th>2021</th><th>2020</th><th>2019</th>
|
||||
<th class="l">2024</th><th>2023</th><th>2022</th><th>2021</th><th>2020</th><th>2019</th>
|
||||
<th class="l">2024</th><th>2023</th><th>2022</th><th>2021</th><th>2020</th><th>2019</th>
|
||||
<th class="l">2024</th><th>2023</th><th>2022</th><th>2021</th><th>2020</th><th>2019</th>
|
||||
<th class="l">Einw. in Tausend</th><th>Quote</th>
|
||||
|
||||
</tr>
|
||||
@ -50,31 +61,35 @@ require("../config.php");
|
||||
|
||||
$strSQL="SELECT d.title as Kreis,
|
||||
district,
|
||||
SUM(UJAHR=2024) as Jahr_2024,
|
||||
SUM(UJAHR=2023) as Jahr_2023,
|
||||
SUM(UJAHR=2022) as Jahr_2022,
|
||||
SUM(UJAHR=2021) as Jahr_2021,
|
||||
SUM(UJAHR=2020) as Jahr_2020,
|
||||
SUM(UJAHR=2019) as Jahr_2019,
|
||||
|
||||
SUM(UJAHR=2024 AND UKATEGORIE=1) as Tode_2024,
|
||||
SUM(UJAHR=2023 AND UKATEGORIE=1) as Tode_2023,
|
||||
SUM(UJAHR=2022 AND UKATEGORIE=1) as Tode_2022,
|
||||
SUM(UJAHR=2021 AND UKATEGORIE=1) as Tode_2021,
|
||||
SUM(UJAHR=2020 AND UKATEGORIE=1) as Tode_2020,
|
||||
SUM(UJAHR=2019 AND UKATEGORIE=1) as Tode_2019,
|
||||
|
||||
SUM(UJAHR=2024 AND UKATEGORIE=2) as Schwerverletzt_2024,
|
||||
SUM(UJAHR=2023 AND UKATEGORIE=2) as Schwerverletzt_2023,
|
||||
SUM(UJAHR=2022 AND UKATEGORIE=2) as Schwerverletzt_2022,
|
||||
SUM(UJAHR=2021 AND UKATEGORIE=2) as Schwerverletzt_2021,
|
||||
SUM(UJAHR=2020 AND UKATEGORIE=2) as Schwerverletzt_2020,
|
||||
SUM(UJAHR=2019 AND UKATEGORIE=2) as Schwerverletzt_2019,
|
||||
|
||||
SUM(UJAHR=2024 AND UKATEGORIE=3) as Leichtverletzt_2024,
|
||||
SUM(UJAHR=2023 AND UKATEGORIE=3) as Leichtverletzt_2023,
|
||||
SUM(UJAHR=2022 AND UKATEGORIE=3) as Leichtverletzt_2022,
|
||||
SUM(UJAHR=2021 AND UKATEGORIE=3) as Leichtverletzt_2021,
|
||||
SUM(UJAHR=2020 AND UKATEGORIE=3) as Leichtverletzt_2020,
|
||||
SUM(UJAHR=2019 AND UKATEGORIE=3) as Leichtverletzt_2019,
|
||||
d.Population as Population,
|
||||
SUM(UJAHR=2023)/d.Population*1000 as Quote_2023,
|
||||
SUM(UJAHR=2024)/d.Population*1000 as Quote_2024,
|
||||
s.ULAND,
|
||||
s.UREGBEZ,
|
||||
s.UKREIS
|
||||
@ -82,35 +97,39 @@ $strSQL="SELECT d.title as Kreis,
|
||||
WHERE IstRad=1
|
||||
AND d.ULAND=s.ULAND AND d.UREGBEZ=s.UREGBEZ AND d.UKREIS=s.UKREIS
|
||||
GROUP BY s.ULAND, s.UREGBEZ, s.UKREIS
|
||||
ORDER BY Quote_2023 DESC;";
|
||||
ORDER BY Quote_2024 DESC;";
|
||||
|
||||
$result=$db->query($strSQL);
|
||||
|
||||
while ($row = $result->fetch(PDO::FETCH_ASSOC)) {
|
||||
echo "<tr>";
|
||||
echo "<td><a href='kreis_details.php?regbez=".$row['UREGBEZ']."&kreis=".$row['UKREIS']."'>".$row['Kreis']."</a></td>";
|
||||
echo "<td class='l'>".$row['Jahr_2023']."</td>";
|
||||
echo "<td class='l'>".$row['Jahr_2024']."</td>";
|
||||
echo "<td>".$row['Jahr_2023']."</td>";
|
||||
echo "<td>".$row['Jahr_2022']."</td>";
|
||||
echo "<td>".$row['Jahr_2021']."</td>";
|
||||
echo "<td>".$row['Jahr_2020']."</td>";
|
||||
echo "<td>".$row['Jahr_2019']."</td>";
|
||||
echo "<td class='l'>".$row['Tode_2023']."</td>";
|
||||
echo "<td class='l'>".$row['Tode_2024']."</td>";
|
||||
echo "<td>".$row['Tode_2023']."</td>";
|
||||
echo "<td>".$row['Tode_2022']."</td>";
|
||||
echo "<td>".$row['Tode_2021']."</td>";
|
||||
echo "<td>".$row['Tode_2020']."</td>";
|
||||
echo "<td>".$row['Tode_2019']."</td>";
|
||||
echo "<td class='l'>".$row['Schwerverletzt_2023']."</td>";
|
||||
echo "<td class='l'>".$row['Schwerverletzt_2024']."</td>";
|
||||
echo "<td>".$row['Schwerverletzt_2023']."</td>";
|
||||
echo "<td>".$row['Schwerverletzt_2022']."</td>";
|
||||
echo "<td>".$row['Schwerverletzt_2021']."</td>";
|
||||
echo "<td>".$row['Schwerverletzt_2020']."</td>";
|
||||
echo "<td>".$row['Schwerverletzt_2019']."</td>";
|
||||
echo "<td class='l'>".$row['Leichtverletzt_2023']."</td>";
|
||||
echo "<td class='l'>".$row['Leichtverletzt_2024']."</td>";
|
||||
echo "<td>".$row['Leichtverletzt_2024']."</td>";
|
||||
echo "<td>".$row['Leichtverletzt_2022']."</td>";
|
||||
echo "<td>".$row['Leichtverletzt_2021']."</td>";
|
||||
echo "<td>".$row['Leichtverletzt_2020']."</td>";
|
||||
echo "<td>".$row['Leichtverletzt_2019']."</td>";
|
||||
echo "<td class='l rechts'>".round($row['Population']/1000,0)."</td>";
|
||||
echo "<td class='rechts'>".round($row['Quote_2023'],2)."</td>";
|
||||
echo "<td class='rechts'>".round($row['Quote_2024'],2)."</td>";
|
||||
echo "</tr>\n";
|
||||
}
|
||||
?>
|
||||
|
@ -55,12 +55,14 @@
|
||||
<div class="col-5">
|
||||
<h4>Unfallverlauf von <?=$numLatestYear?> bis <?=$numStartYear?></h4>
|
||||
<table class='table table-sm'>
|
||||
<tr><th></th><th>2023</th><th>2022</th><th>2021</th><th>2020</th><th>2019</th></tr>
|
||||
<tr><th></th><th>2024</th><th>2023</th><th>2022</th><th>2021</th><th>2020</th><th>2019</th></tr>
|
||||
<tr><td><?= $arrCategory[1]?></td><?= get_row($resultVerlauf,1) ?></tr>
|
||||
<tr><td><?= $arrCategory[2]?></td><?= get_row($resultVerlauf,2) ?></tr>
|
||||
<tr><td><?= $arrCategory[3]?></td><?= get_row($resultVerlauf,3) ?></tr>
|
||||
<tr><th>Gesamt</th><?= get_row($resultVerlauf,0) ?></tr>
|
||||
</table>
|
||||
<p><strong>Beachte:</strong> Die Zahlen beziehen sich auf die Unfälle, die eindeutig einer Straße zugeordent werden konnten
|
||||
und entsprechen laut IT.NRW nur ca. 90 % der insgesamt erfassten Unfälle.</p>
|
||||
</div>
|
||||
<div class="col-7">
|
||||
<div id="c_unfallverlauf"></div>
|
||||
|
Loading…
Reference in New Issue
Block a user