here try this
PHP Code:
$shops = $DB_site->query("SELECT * FROM itemshops DESC LIMIT 3");
while ($shop = $DB_site->fetch_array($shops)) {
$i = 1;
$shop_id$i = $shop[shop_id];
$shop_name$i = $shop[shop_name];
$shop_image$i = $shop[shop_image];
$shop_rating$i = $shop[shop_rating];
$shop_profit$i = $shop[shop_profit];
$shop_total$i = $shop[shop_total];
$i++;
}
that will select the first 3 rows from your database and put each variable into for example
$shop_id1 will be the first shops id
and
$shop_total2 will be the second shops total
im pretty sure this should work