Answer the question
In order to leave comments, you need to log in
How to track categories?
There is a website, a regular online store, I started to create an admin panel, I think - how to do something that the admin could add categories, and products were displayed from them:
Here is the code for displaying products from the database on the page:
<div class="items">
<?
$goods_perm = mysqli_query($link, "SELECT * FROM `donate` WHERE type='surv-case' ORDER BY `price`");
while ($row = mysqli_fetch_assoc($goods_perm)) {
$perm_id = $row['id'];
$perm_name = $row['name'];
$perm_img = $row['img-url'];
$perm_price = $row['price'];
$perm_price_old = $row['price-old'];
$perm_sale = $row['sale'];
$group_perm = $row['group-perm'];
?>
<div class="item-id js-open-modal" data-modal="paymodal" id="openModal" data-prices="<?=$perm_price?>" data-product="<?=$perm_name?>" data-server="<?=$server?>" data-group="<?=$group_perm?>">
<div class="title"><?=$perm_name?></div>
<div class="sale">-<?=$perm_sale?>%</div>
<div class="image" style="background-image: url('<?=$perm_img?>');"></div>
<div class="price"><?=$perm_price?>.00 <i class="fa fa-ruble"></i></div>
</div>
<?}?>
</div>
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question