Update index.html
This commit is contained in:
parent
4e7e710bf5
commit
e091a548fb
@ -235,15 +235,10 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Добавляем внизу кнопку для обновления данных
|
// Обновляем сайт каждые 5 секунд для получения актуальных данных
|
||||||
const container = document.querySelector(".container");
|
setInterval(() => {
|
||||||
const updateButton = document.createElement("button");
|
|
||||||
updateButton.textContent = "🔄 Обновить данные"
|
|
||||||
updateButton.classList.add("button");
|
|
||||||
updateButton.addEventListener("click", () => {
|
|
||||||
window.location.reload();
|
window.location.reload();
|
||||||
});
|
}, 5000);
|
||||||
container.appendChild(updateButton);
|
|
||||||
</script>
|
</script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
Loading…
Reference in New Issue
Block a user