Files
Advertisement_Panel/static/index.html
2025-08-14 22:39:08 +02:00

42 lines
911 B
HTML

<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>IMAGES</title>
<style>
body {
margin: 0;
background: black;
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
}
img {
max-width: 100%;
max-height: 100%;
}
</style>
</head>
<body>
<img id="images" src="img1.jpg" alt="images">
<script>
fetch("/files")
.then(res => res.json())
.then(files => {
console.log(files);
const images = files
let index = 0;
setInterval(() => {
index = (index + 1) % images.length;
document.getElementById("images").src = images[index];
}, 10000);
});
</script>
</body>
</html>