cleaned up source code
This commit is contained in:
parent
eb6b9e9b97
commit
26ecb2596f
@ -1,7 +1,3 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
$uID = $_SESSION['user'];
|
|
||||||
?>
|
|
||||||
<p></p>
|
<p></p>
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
@ -16,70 +12,91 @@ $uID = $_SESSION['user'];
|
|||||||
|
|
||||||
<div class="card-columns">
|
<div class="card-columns">
|
||||||
|
|
||||||
<!--start of card -->
|
<!--start of cards -->
|
||||||
<?php
|
<?php
|
||||||
$stmt = $database->prepare("SELECT * FROM entries WHERE userID = '$uID'");
|
$uID = 0;
|
||||||
$stmt->execute();
|
$uID = $_SESSION['user'];
|
||||||
$result = $stmt->get_result();
|
$stmt = $database->prepare("SELECT * FROM entries WHERE userID = '$uID'");
|
||||||
while ($row = $result->fetch_assoc()) {
|
$stmt->execute();
|
||||||
|
$result = $stmt->get_result();
|
||||||
|
while ($row = $result->fetch_assoc()) {
|
||||||
|
|
||||||
echo '<div class="card">';
|
echo'<div class="card">';
|
||||||
echo ' <div class="card-body">';
|
echo'<div class="card-body">';
|
||||||
echo ' <h5 class="card-title">' .$row['vorname'] . ' ' .$row['nachname'] . '</h5>';
|
echo'<h5 class="card-title">' . $row['vorname'] . ' ' . $row['nachname'] . '</h5>';
|
||||||
if(!empty($row['geburtstag'])){ echo ' <p class="card-text">Geburtstag: ' . $row['geburtstag'] . '</p>';}
|
if(!empty($row['geburtstag'])){
|
||||||
if(!empty($row['wohnort'])){ echo ' <p class="card-text">Wohnort: ' . $row['wohnort'] . '</p>';}
|
echo'<p class="card-text">Geburtstag: ' . $row['geburtstag'] . '</p>';
|
||||||
if(!empty($row['strasse'])){ echo ' <p class="card-text">Straße: ' . $row['strasse'] .'</p>';}
|
}
|
||||||
if(!empty($row['kennenUns'])){ echo ' <p class="card-text">Woher kennen wir uns? ' . $row['kennenUns'] . '</p>';}
|
if(!empty($row['wohnort'])){
|
||||||
if(!empty($row['festnetz'])){ echo ' <p class="card-text">Festnetz: ' . $row['festnetz'] .'</p>';}
|
echo'<p class="card-text">Wohnort: ' . $row['wohnort'] . '</p>';
|
||||||
if(!empty($row['handynummer'])){ echo ' <p class="card-text">Handynummer:' . $row['handynummer'] .'</p>';}
|
}
|
||||||
if(!empty($row['email'])){ echo ' <p class="card-text">E-Mail: ' . $row['email'] .'</p>';}
|
if(!empty($row['strasse'])){
|
||||||
if(!empty($row['hobbies'])){ echo ' <p class="card-text">Hobbies:' . $row['hobbies'] .' </p>';}
|
echo'<p class="card-text">Straße: ' . $row['strasse'] . '</p>';
|
||||||
if(!empty($row['berufswunsch'])){ echo ' <p class="card-text">Berufswunsch: ' . $row['berufswunsch'] .'</p>';}
|
}
|
||||||
if(!empty($row['essen'])){ echo ' <p class="card-text">Das könnte ich jeden Tag essen: ' . $row['essen'] .'</p>';}
|
if(!empty($row['kennenUns'])){
|
||||||
if(!empty($row['insel'])){ echo ' <p class="card-text">Was ich auf eine Insel mitnehmen würde: '. $row['insel'] .'</p>';}
|
echo'<p class="card-text">Woher kennen wir uns? ' . $row['kennenUns'] . '</p>';
|
||||||
if(!empty($row['film'])){ echo ' <p class="card-text">Lieblingsfilm: '. $row['film'] .'</p>';}
|
}
|
||||||
if(!empty($row['sport'])){ echo ' <p class="card-text">Lieblingssport: '. $row['sport'] .'</p>';}
|
if(!empty($row['festnetz'])){
|
||||||
if(!empty($row['charakter'])){ echo ' <p class="card-text">Coolster Film oder Spielecharakter: '. $row['charakter'] .'</p>';}
|
echo'<p class="card-text">Festnetz: ' . $row['festnetz'] . '</p>';
|
||||||
if(!empty($row['tier'])){ echo ' <p class="card-text">Mein Lieblingstier: '. $row['tier'] .'</p>';}
|
}
|
||||||
if(!empty($row['musik'])){ echo ' <p class="card-text">Lieblingsmusik:'. $row['musik'] .' </p>';}
|
if(!empty($row['handynummer'])){
|
||||||
if(!empty($row['game'])){ echo ' <p class="card-text">Geilstes Game: '. $row['game'] .'</p>';}
|
echo'<p class="card-text">Handynummer:' . $row['handynummer'] . '</p>';
|
||||||
if(!empty($row['story'])){ echo ' <p class="card-text">Lieblings alkoholisches Getränk: ' . $row['alk'] .'</p>';}
|
}
|
||||||
if(!empty($row['geburtstag'])){ echo ' <p class="card-text">Meine heftigeste Suffstory: '. $row['story'] .'</p>';}
|
if(!empty($row['email'])){
|
||||||
if(!empty($row['absturz'])){ echo ' <p class="card-text">Letzter Absturz: '. $row['absturz'] . '</p>';}
|
echo'<p class="card-text">E-Mail: ' . $row['email'] . '</p>';
|
||||||
if(!empty($row['trinkspiel'])){ echo ' <p class="card-text">Lieblings Trinkspiel: '. $row['trinkspiel'] .'</p>';}
|
}
|
||||||
echo ' </div>';
|
if(!empty($row['hobbies'])){
|
||||||
echo ' </div>';
|
echo'<p class="card-text">Hobbies:' . $row['hobbies'] . ' </p>';
|
||||||
|
}
|
||||||
|
if(!empty($row['berufswunsch'])){
|
||||||
|
echo'<p class="card-text">Berufswunsch: ' . $row['berufswunsch'] . '</p>';
|
||||||
|
}
|
||||||
|
if(!empty($row['essen'])){
|
||||||
|
echo'<p class="card-text">Das könnte ich jeden Tag essen: ' . $row['essen'] . '</p>';
|
||||||
|
}
|
||||||
|
if(!empty($row['insel'])){
|
||||||
|
echo'<p class="card-text">Was ich auf eine Insel mitnehmen würde: ' . $row['insel'] . '</p>';
|
||||||
|
}
|
||||||
|
if(!empty($row['film'])){
|
||||||
|
echo'<p class="card-text">Lieblingsfilm: ' . $row['film'] . '</p>';
|
||||||
|
}
|
||||||
|
if(!empty($row['sport'])){
|
||||||
|
echo'<p class="card-text">Lieblingssport: ' . $row['sport'] . '</p>';
|
||||||
|
}
|
||||||
|
if(!empty($row['charakter'])){
|
||||||
|
echo'<p class="card-text">Coolster Film oder Spielecharakter: ' . $row['charakter'] . '</p>';
|
||||||
|
}
|
||||||
|
if(!empty($row['tier'])){
|
||||||
|
echo'<p class="card-text">Mein Lieblingstier: ' . $row['tier'] . '</p>';
|
||||||
|
}
|
||||||
|
if(!empty($row['musik'])){
|
||||||
|
echo'<p class="card-text">Lieblingsmusik:' . $row['musik'] . '</p>';
|
||||||
|
}
|
||||||
|
if(!empty($row['game'])){
|
||||||
|
echo'<p class="card-text">Geilstes Game: ' . $row['game'] . '</p>';
|
||||||
|
}
|
||||||
|
if(!empty($row['story'])){
|
||||||
|
echo'<p class="card-text">Lieblings alkoholisches Getränk: ' . $row['alk'] . '</p>';
|
||||||
|
}
|
||||||
|
if(!empty($row['geburtstag'])){
|
||||||
|
echo'<p class="card-text">Meine heftigeste Suffstory: ' . $row['story'] . '</p>';
|
||||||
|
}
|
||||||
|
if(!empty($row['absturz'])){
|
||||||
|
echo'<p class="card-text">Letzter Absturz: ' . $row['absturz'] . '</p>';
|
||||||
|
}
|
||||||
|
if(!empty($row['trinkspiel'])){
|
||||||
|
echo'<p class="card-text">Lieblings Trinkspiel: ' . $row['trinkspiel'] . '</p>';
|
||||||
|
}
|
||||||
|
|
||||||
|
echo'</div>'; //Close Card Body
|
||||||
|
echo'</div>'; //Close Card
|
||||||
|
}
|
||||||
|
|
||||||
}
|
|
||||||
?>
|
?>
|
||||||
<!-- end of card -->
|
|
||||||
|
|
||||||
<!-- end of card -->
|
|
||||||
</div>
|
</div>
|
||||||
<!-- end of card-colums-->
|
<!-- end of card-colums-->
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
<!-- jumbotron for a single entry -->
|
|
||||||
<!--<div class="jumbotron">
|
|
||||||
<h1 class="display-4">Name Nachname!</h1>
|
|
||||||
<p class="lead">Geburtstag:</p>
|
|
||||||
<p>DB-entry</p>
|
|
||||||
<hr/>
|
|
||||||
<p class="lead">Wohnort:</p>
|
|
||||||
<p>DB-entry</p>
|
|
||||||
<hr/>
|
|
||||||
<p class="lead">Straße:</p>
|
|
||||||
<p>DB-entry</p>
|
|
||||||
<hr/>
|
|
||||||
<p class="lead">Woher kennen wir uns:</p>
|
|
||||||
<p>DB-entry</p>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
-->
|
|
||||||
<!-- end of jumbotron -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div> <!-- Ende container My FriendsBook -->
|
</div> <!-- Ende container My FriendsBook -->
|
||||||
|
Loading…
Reference in New Issue
Block a user