<?php
include '../includes/db.php';

$stmt = $conn->prepare("SELECT versionnr FROM news WHERE kategorie = 'Update' AND versionnr != '' ORDER BY erstellt_am DESC LIMIT 1");
$stmt->execute();
$result = $stmt->get_result();
$version = $result->fetch_assoc()['versionnr'] ?? '1.0';

echo $version;
