I have a big problem with the selection of the table. I want to show me from the highest to the smallest, just that it appears to me like this
NAME `POINTS`
John Doe 0
John Doe2 432
John Doe3 64
John Doe4 0
John Doe5 138
I want to show from the highest to the smallest and in the database there is someone who has over 432 points just does not show it
<?php
$query = sql()->query('SELECT * FROM `PlayersData` WHERE `Points` BETWEEN 0 AND 1000 LIMIT 5');
if( $query->num_rows == 0 ) {
echo '<div class="nores">No records found.</div>';
} else {
while( $row = $query->fetch_object() ) {
$row = (object) $row;
?>
<div class="row">
<div><?php echo $row->SteamID ?></div>
<div>
<?php echo $row->Points ?> </div>
</div>
<?php
}
}
?>