Add external download path support

This commit is contained in:
2026-07-24 23:43:36 +02:00
parent 6341a8fde5
commit afa8db8eff
4 changed files with 45 additions and 6 deletions
+15 -1
View File
@@ -31,16 +31,29 @@
NO MID NO FEED
</p>
<?php if (empty($options[$os_guess]["download_path"])): ?>
<a class="recommended build disabled">
<div>
Download unavailable
</div>
</a>
<?php else: ?>
<a class="recommended build" href="<?= $options[$os_guess]["download_path"] ?>" download="<?= $options[$os_guess]["download_filename"] ?>">
<div>
Download for <?= $options[$os_guess]["name"] ?>
</div>
</a>
<?php endif; ?>
<?php if ($display_other_builds): ?>
<ul class="other-builds">
<p>Other builds</p>
<?php foreach($options as $os => $target): ?>
<?php
if (empty($target["download_path"])) {
continue;
}
?>
<li>
<a class="other build" href="<?= $target["download_path"] ?>" download="<?= $target["download_filename"] ?>">
<?= $target["name"] ?><span class="architecture"><?= $target["architecture"] ?></span>
@@ -48,6 +61,7 @@
</li>
<?php endforeach; ?>
</ul>
<?php endif; ?>
</main>
<footer>
<p>In case of any questions, message <a href="<?= $contact_link ?>"><?= $contact_name ?></a>.</p>