added username to profile table

removed db connection cause its not needed here anymore
This commit is contained in:
Thies Mueller 2021-01-08 18:18:24 +01:00
parent 7f6492b282
commit 2a7e8aed98

View File

@ -7,7 +7,6 @@
<script src="ressources/js/bootstrap.min.js"></script> <script src="ressources/js/bootstrap.min.js"></script>
<?php <?php
session_start(); session_start();
$pdo = new PDO('mysql:host=localhost;dbname=usertable', 'usertable', 'password');
if(!isset($_SESSION['userid'])) { if(!isset($_SESSION['userid'])) {
die('Please <a href="login.php">login</a>'); die('Please <a href="login.php">login</a>');
} }
@ -23,6 +22,14 @@ echo "<br/>";
echo '<table class="table table-dark table-striped" style="width:30%">'; echo '<table class="table table-dark table-striped" style="width:30%">';
echo "<tr>"; echo "<tr>";
echo "<td>"; echo "<td>";
echo "Username";
echo "</td>";
echo "<td>";
echo $username;
echo "</td>";
echo "</tr>";
echo "<tr>";
echo "<td>";
echo "User-ID"; echo "User-ID";
echo "</td>"; echo "</td>";
echo "<td>"; echo "<td>";