<?php
$pages = json_decode(file_get_contents('pages.json'), true);
$page = $_GET['page'] ?? 'home';
if (!isset($pages[$page])) {
$page = 'home';
}
$pageData = $pages[$page];
$contentFile = basename($pageData['file']);
$contentFilePath = "content/{$contentFile}";
?>
<html>
<head>
<title><?= htmlspecialchars($pageData['title']) ?></title>
</head>
<body>
<main>
<?php include $contentFilePath; ?>
</main>
</body>
</html>
Slightly more, but the base principle is the same. Just 10 lines of php code, and now I can just add pages by uploading their contents and adding them to the json file for whitelisting. For your use case it would be trivial to add a menu based on the json file and I'd be confident that it will still work in 10 years with minimal adjustments.
That is a pretty big missing part. Not as big as the galaxy, but still huge.