tabelle anzeigen

This commit is contained in:
Göran Heinemann 2020-03-08 14:06:07 +01:00
parent a5eeee48cc
commit 0d7a10d969

View File

@ -22,7 +22,7 @@ if(isset($_GET['land'])){
$stmt->bindParam(1, $like); $stmt->bindParam(1, $like);
$stmt->execute(); $stmt->execute();
$data = $stmt->fetchAll(PDO::FETCH_ASSOC); $data = $stmt->fetchAll(PDO::FETCH_ASSOC);
/*echo '<table style="width: 100%">'; echo '<table style="width: 100%">';
echo '<tr><th>id</th><th>Scan-No</th><th>infected</th><th>dead</th><th>active</th><th>cured</th><th>time</th></tr>'; echo '<tr><th>id</th><th>Scan-No</th><th>infected</th><th>dead</th><th>active</th><th>cured</th><th>time</th></tr>';
foreach ($data as $row){ foreach ($data as $row){
echo '<tr>'; echo '<tr>';
@ -30,12 +30,12 @@ if(isset($_GET['land'])){
echo '<td>'.$item.'</td>'; echo '<td>'.$item.'</td>';
} }
echo '</tr>'; echo '</tr>';
}*/ }
echo '</table>'; echo '</table>';
} }
?> ?>
<div class="container"> <div class="container" style="height: 40vh; width: 80vh; position: relative">
<canvas id="myChart"></canvas> <canvas id="myChart"></canvas>
</div> </div>
@ -91,6 +91,8 @@ if(isset($_GET['land'])){
}] }]
}, },
options:{ options:{
responsive: false,
maintainAspectRatio: false,
title:{ title:{
display:true, display:true,
text:'Anzahl der Infektionsfälle in <?php echo $_GET['land']?>', text:'Anzahl der Infektionsfälle in <?php echo $_GET['land']?>',