commit
This commit is contained in:
+16
-1
@@ -80,7 +80,7 @@
|
||||
<h1 id="radio" class="display-5 fw-bold lh-1 mb-3">Live als Stream</h1>
|
||||
<p class="lead">Immer samstags und sonntags ab 15:00 Uhr im</p>
|
||||
<p class="text-center">
|
||||
<a class="btn btn-primary btn-lg px-4 me-sm-3" href="https://www.nodebucket.de:8444/radioanton">Livestream</a>
|
||||
<a id="streamBtn" class="btn btn-primary btn-lg px-4 me-sm-3" href="https://www.nodebucket.de:8444/radioanton">Livestream</a>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
@@ -452,6 +452,21 @@
|
||||
<script src="{{ theme_url }}/js/utils.js" type="text/javascript"></script>
|
||||
<script src="{{ theme_url }}/js/pico.js" type="text/javascript"></script>
|
||||
-->
|
||||
<script>
|
||||
const element = document.getElementById("streamBtn");
|
||||
setInterval(function() {
|
||||
const d = new Date();
|
||||
let day = d.getDay();
|
||||
let hour = d.getHours();
|
||||
|
||||
if ((day == 0 || day == 6) && (hour >= 15 && hour <= 18)) {
|
||||
document.getElementById("streamBtn").classList.add("disabled");
|
||||
}
|
||||
else {
|
||||
document.getElementById("streamBtn").classList.remove("disabled");
|
||||
}
|
||||
}, 1000);
|
||||
</script>
|
||||
|
||||
<!--script>
|
||||
// When the user scrolls down 80px from the top of the document, resize the navbar's padding and the logo's font size
|
||||
|
||||
Reference in New Issue
Block a user