<h5>Фильтр</h5>
<div class="list-group">
<a href="#" class="list-group-item list-group-item-action">Показать все</a>
<a href="#" class="list-group-item list-group-item-action">Intel Core i9</a>
<a href="#" class="list-group-item list-group-item-action">Intel Core i7</a>
<a href="#" class="list-group-item list-group-item-action">Intel Core i5</a>
<a href="#" class="list-group-item list-group-item-action">Intel Core i3</a>
<a href="#" class="list-group-item list-group-item-action">Intel Core Pentium</a>
</div>
<h5>Каталог товаров</h5>
<?php
$sql = $link->query("SELECT * FROM `cpu-i7`");
$link->close;
while($result = $sql->fetch_assoc()): ?>
<div class="media" style="background-color: ">
<img class="mr-2" width="140px" src="<?=$result['img']?>">
<div class="media-body">
<h5 class="mt-0"><?=$result['title']?></h5>
<p><?=$result['text']?></p>
<h5><?=$result['price']?></h5>
</div>
</div>
<? endwhile ?>
<a href="?cpu=cpu-i7" class="list-group-item list-group-item-action">Intel Core i7</a>
$sql = $link->query('SELECT * FROM ' . $_GET['cpu'] . ';');