// Affichage des objets classement 1. $objets1query = doquery ("SELECT weaponname, count(weaponid) as occurences FROM {{table}} WHERE weaponid >= 0 GROUP BY weaponid ORDER by occurences DESC LIMIT 5","users"); $objets1query = doquery ("SELECT u.weaponname, count(u.weaponid) as occurences, i.buycost, i.image, i.special FROM {{table}} AS u, rpg_items AS i WHERE u.weaponid >= 0 AND i.id = u.weaponid GROUP BY u.weaponid ORDER by occurences DESC LIMIT 5","users"); $weapon =''; $row = '0'; while ($row = mysql_fetch_array($objets1query)) { $weapon .='
Nom: ' . $row['weaponname'] . '
Prix: ' . $row['buycost'] . ' rubis
Equipé: ... perso.
'; }