<html>
<head>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-BmbxuPwQa2lc/FVzBcNJ7UAyJxM6wuqIj61tLrc4wSX0szH/Ev+nYRRuWlolflfl" crossorigin="anonymous">
</head>
<title>Лучшие креативы L</title>
<body>
<?php
require_once 'config.php';
$sql = "SELECT * FROM products";
$stmt = $pdo->prepare($sql);
$stmt->execute();
?>
<table border = '1'>
<?php
while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) {
echo '<div class="col-sm-12 col-md-6 col-lg-4 col-xl-3">';
echo '<div>' . $row['product_id'] . '</div>';
echo '<div>' . $row['product_name'] . '</div>';
echo '<div>' . $row['price'] . '</div>';
echo '<div>' . $row['opis'] . '</div>';
echo '<div>' . $row['socs'] . '</div>';
echo '<div>' .
'<img src = "data:image/png;base64,' . base64_encode($row['product_image']) . '" width = "250px" height = "250px"/>'
. '</div>';
echo '</div>';
}
?>
</table>
</body>
</html>