Commit 536a4a2a authored by Nicolas Guilbert's avatar Nicolas Guilbert

Fix image gallery, latest image needs special casing

parent 9cc99721
......@@ -21,14 +21,14 @@
robotId = url.searchParams.get("robotId");
for (var i = 0; i < 10; ++i) {
imgs[i] = document.createElement('img');
imgs[i].src = "/read/photo/" + robotId + "/" + -i;
imgs[i].src = "/read/photo/" + robotId + (i == 0? "" : "/" + -i);
document.getElementById('images').appendChild(imgs[i])
}
}
setInterval(function() {
for (var i = 0; i < 10; ++i) {
imgs[i].src = "/read/photo/" + robotId + "/" + -i + "#" + new Date().getTime();
imgs[i].src = "/read/photo/" + robotId + (i == 0? "" : "/" + -i) + "#" + new Date().getTime();
}
}, 3000);
</script>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment