<?php
require_once __DIR__."/../config.php";
require_once __DIR__."/../middleware/user_auth.php";

$user = $_SESSION['user_id'];

$q = $conn->query("
SELECT *
FROM fxh_positions
ORDER BY last_update DESC
");

$out=[];

while($row=$q->fetch_assoc()){
    $out[] = $row;
}

echo json_encode($out);
