Spaces:
Running
Running
Commit
·
a0daf23
1
Parent(s):
97178e5
Update templates/index.html
Browse files- templates/index.html +3 -1
templates/index.html
CHANGED
@@ -278,6 +278,8 @@
|
|
278 |
const infoDiv = document.getElementById("info");
|
279 |
const infoText = document.getElementById("info-text");
|
280 |
infoText.style.opacity = "0";
|
|
|
|
|
281 |
|
282 |
const locationName = document.getElementById('location-name');
|
283 |
locationName.textContent = "{{ page_title|safe }}";
|
@@ -294,6 +296,7 @@
|
|
294 |
if (xhr.readyState === 4 && xhr.status === 200) {
|
295 |
if (xhr.getResponseHeader('Content-Type') === 'image/jpeg') {
|
296 |
img.src = newUrl + "?r=" + new Date().getTime();
|
|
|
297 |
isJpeg = true;
|
298 |
contentTypeChecked = true;
|
299 |
}
|
@@ -337,7 +340,6 @@
|
|
337 |
console.log("Image loading failed:", event);
|
338 |
|
339 |
const urlParams = new URLSearchParams(window.location.search);
|
340 |
-
const countryElement = document.getElementById("country");
|
341 |
if (urlParams.get('new') === 'false') {
|
342 |
countryElement.textContent = "couldn't connect.";
|
343 |
}
|
|
|
278 |
const infoDiv = document.getElementById("info");
|
279 |
const infoText = document.getElementById("info-text");
|
280 |
infoText.style.opacity = "0";
|
281 |
+
|
282 |
+
const countryElement = document.getElementById("country");
|
283 |
|
284 |
const locationName = document.getElementById('location-name');
|
285 |
locationName.textContent = "{{ page_title|safe }}";
|
|
|
296 |
if (xhr.readyState === 4 && xhr.status === 200) {
|
297 |
if (xhr.getResponseHeader('Content-Type') === 'image/jpeg') {
|
298 |
img.src = newUrl + "?r=" + new Date().getTime();
|
299 |
+
countryElement.textContent = "connecting...";
|
300 |
isJpeg = true;
|
301 |
contentTypeChecked = true;
|
302 |
}
|
|
|
340 |
console.log("Image loading failed:", event);
|
341 |
|
342 |
const urlParams = new URLSearchParams(window.location.search);
|
|
|
343 |
if (urlParams.get('new') === 'false') {
|
344 |
countryElement.textContent = "couldn't connect.";
|
345 |
}
|