T201704101351
This commit is contained in:
@@ -13,8 +13,8 @@ $limit = isset($_GET['limit']) ? $_GET['limit'] : 10;
|
|||||||
$offset = isset($_GET['offset']) ? $_GET['offset'] : 0;
|
$offset = isset($_GET['offset']) ? $_GET['offset'] : 0;
|
||||||
$db = new Database();
|
$db = new Database();
|
||||||
|
|
||||||
$overview = $db->query('SELECT "name", "highscore" FROM "Users" LIMIT $1 OFFSET $2
|
$overview = $db->query('SELECT "name", "highscore" FROM "Users" ORDER BY "highscore" DESC
|
||||||
ORDER BY "highscore" DESC', array($limit, $offset))['data'];
|
LIMIT $1 OFFSET $2', array($limit, $offset))['data'];
|
||||||
foreach($overview as $row) {
|
foreach($overview as $row) {
|
||||||
$name = $row['name'];
|
$name = $row['name'];
|
||||||
$score = $row['highscore'];
|
$score = $row['highscore'];
|
||||||
|
|||||||
Reference in New Issue
Block a user