2022-04-19 16:38:20 +02:00
|
|
|
<!DOCTYPE html>
|
|
|
|
|
<?php
|
|
|
|
|
include "kozos/kapcsolat.php";
|
|
|
|
|
|
|
|
|
|
$firms = $kapcsolat->readAll($kapcsolat->getDBC(), 'firms');
|
|
|
|
|
|
|
|
|
|
print_r($firms);
|
|
|
|
|
echo "<hr>";
|
|
|
|
|
?>
|
|
|
|
|
<html>
|
|
|
|
|
<head>
|
|
|
|
|
<meta charset="UTF-8">
|
|
|
|
|
<title>Firms</title>
|
|
|
|
|
<link href="kozos/bootstrap.min.css" rel="stylesheet" type="text/css"/>
|
|
|
|
|
</head>
|
|
|
|
|
<body>
|
|
|
|
|
<div class="container-fluid w-75">
|
|
|
|
|
<a class="btn btn-info" href="insert.php">Hozzáadás</a>
|
|
|
|
|
<table class="table table-info table-striped my-3" >
|
|
|
|
|
<tr>
|
|
|
|
|
<?php foreach ($firms[0] as $key => $value) : ?>
|
|
|
|
|
<th><?= $key; ?></th>
|
|
|
|
|
<?php endforeach; ?>
|
|
|
|
|
<!--Műveletek oszlop -->
|
|
|
|
|
<th colspan='3' style="text-align: center; width:20%;" >Műveletek</th>
|
|
|
|
|
</tr>
|
|
|
|
|
<?php foreach ($firms as $sor) : ?>
|
|
|
|
|
<tr>
|
|
|
|
|
<?php foreach ($sor as $key => $value) : ?>
|
|
|
|
|
<?php if ($key == 'kep') : ?>
|
|
|
|
|
<td><img class="img-thumbnail" src="img/<?= $value; ?>" /></td>
|
|
|
|
|
<?php else : ?>
|
|
|
|
|
<td><?= $value; ?></td>
|
|
|
|
|
<?php endif; ?>
|
|
|
|
|
<?php endforeach; ?>
|
|
|
|
|
<!--Műveletek létrehozás id oszlopra -->
|
|
|
|
|
<div >
|
2022-04-20 20:52:00 +02:00
|
|
|
<td><a class="btn btn-info" href="firms_view.php?id=<?= $sor['id']; ?>"> Megtekint </a></td>
|
2022-04-19 16:38:20 +02:00
|
|
|
<td><a class="btn btn-info" href="update.php?id=<?= $sor['id']; ?>"> Szerkeszt </a></td>
|
|
|
|
|
<td><a class="btn btn-info" href="delete.php?id=<?= $sor['id']; ?>"> Töröl </a></td>
|
|
|
|
|
</div>
|
|
|
|
|
</tr>
|
|
|
|
|
<?php endforeach; ?>
|
|
|
|
|
</table>
|
|
|
|
|
<a class="btn btn-info" href="index.php">Vissza</a>
|
|
|
|
|
</div>
|
|
|
|
|
<script src="kozos/bootstrap.min.js" type="text/javascript"></script>
|
|
|
|
|
</body>
|
|
|
|
|
</html>
|