diff --git a/arrivals/american.png b/arrivals/american.png new file mode 100644 index 0000000..6e7112b Binary files /dev/null and b/arrivals/american.png differ diff --git a/arrivals/clock.js b/arrivals/clock.js new file mode 100644 index 0000000..33a4181 --- /dev/null +++ b/arrivals/clock.js @@ -0,0 +1,9 @@ +function updateTime() { + const timeElement = document.getElementById('time'); + const now = new Date(); + const hours = String(now.getHours()).padStart(2, '0'); + const minutes = String(now.getMinutes()).padStart(2, '0'); + timeElement.textContent = `${hours}:${minutes}`; +} +setInterval(updateTime, 1000); +updateTime(); diff --git a/arrivals/emirates.png b/arrivals/emirates.png new file mode 100644 index 0000000..806d5cb Binary files /dev/null and b/arrivals/emirates.png differ diff --git a/arrivals/ercss.css b/arrivals/ercss.css new file mode 100644 index 0000000..3ad5e74 --- /dev/null +++ b/arrivals/ercss.css @@ -0,0 +1,120 @@ +body { + margin: 0px; + background-color: #241571; +} + +h1.maintxt{ + font-family:'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; + display: inline; + font-size: 48px; + padding-left: 10px; +} + +.header{ + display: flex; + align-items: center; + justify-content: space-between; + padding: 10px; +} + +#italian{ + color:aliceblue; + font-weight: bolder; +} +#time{ + text-align: right; + color: aliceblue; + margin-left: auto; +} +#english{ + color: gold; + font-weight: lighter; +} + +.arr_logo{ + display: inline-block; + background-color: aliceblue; + border-radius: 4px; +} + +.arr_logo img{ + display: block; +} + +.separator{ + border: none; + border-top: 5px solid #151e3d; + margin: 0px 0; + width: 100%; + margin-left: auto; + margin-right: auto; +} + +table{ + border-collapse: collapse; + width: 100%; +} + +th, td{ + padding: 8px; + text-align: left; + border-bottom: 3px; +} + +th{ + font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; + font-weight: bold; + color: aliceblue; + font-size: 24px; +} + +tr.one{ + background-color: #151e3d; + font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; + font-weight: lighter; + color: aliceblue; + font-size: 24px; +} + +tr.two{ + background-color: #241571; + font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; + font-weight: lighter; + color: aliceblue; + font-size: 24px; +} + +.airline{ + display: inline-block; + margin-bottom: -6px; +} + +.ok{ + width: 24px; + height: 24px; + background-color: lime; + border-radius: 50%; + display: inline-block; + margin-bottom: -3px; + margin-left: 10px; +} + +.late{ + width: 24px; + height: 24px; + background-color: yellow; + border-radius: 50%; + display: inline-block; + margin-bottom: -3px; + margin-left: 10px; +} + +.verylate{ + width: 24px; + height: 24px; + background-color: red; + border-radius: 50%; + display: inline-block; + margin-bottom: -3px; + margin-left: 10px; +} \ No newline at end of file diff --git a/arrivals/flightdata.js b/arrivals/flightdata.js new file mode 100644 index 0000000..4484d0e --- /dev/null +++ b/arrivals/flightdata.js @@ -0,0 +1,34 @@ +window.onload = function() { + startUpdating(); + } + + function startUpdating() { + setInterval(updateTableData, 1000); + } + + function updateTableData() { + const url = 'https://enriifr.github.io/arrivalscreen/flights.txt'; + const cacheBuster = `?v=${new Date().getTime()}`; + const fetchUrl = url + cacheBuster; + + fetch(fetchUrl) + .then(response => response.text()) + .then(data => { + const dataLines = data.split('\n'); + + for (let i = 0; i < 10; i++) { + const flightIndex = i*5; // Each flight has 5 lines of data in the text file + + // Update text content for each flight (assuming data is structured in blocks of 5 lines per flight) + document.getElementById(`flight${i + 1}data1`).textContent = dataLines[flightIndex]; + document.getElementById(`flight${i + 1}data2`).textContent = dataLines[flightIndex + 2]; + document.getElementById(`flight${i + 1}data3`).textContent = dataLines[flightIndex + 3]; + document.getElementById(`flight${i + 1}data4`).textContent = dataLines[flightIndex + 4]; + + // Update image source for each flight + document.getElementById(`flight${i + 1}airline`).src = dataLines[flightIndex + 1]; + } + }) + .catch(error => console.error('Error loading text:', error)); + } + \ No newline at end of file diff --git a/arrivals/flights.txt b/arrivals/flights.txt new file mode 100644 index 0000000..39e4c1a --- /dev/null +++ b/arrivals/flights.txt @@ -0,0 +1,5 @@ +13:33 +RYANAIR.PNG +FR 7266 +BOLOGNA +VICHI MANUEL ON BOARD \ No newline at end of file diff --git a/arrivals/icon.png b/arrivals/icon.png new file mode 100644 index 0000000..fae9d07 Binary files /dev/null and b/arrivals/icon.png differ diff --git a/arrivals/index.html b/arrivals/index.html new file mode 100644 index 0000000..b521f68 --- /dev/null +++ b/arrivals/index.html @@ -0,0 +1,102 @@ + + + + LIPE Arrivals + + + + + + + + +
+ +

Arrivi

+

Arrivals

+

+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
---------------
+ + \ No newline at end of file diff --git a/arrivals/ita.png b/arrivals/ita.png new file mode 100644 index 0000000..a168074 Binary files /dev/null and b/arrivals/ita.png differ diff --git a/arrivals/oscript.js b/arrivals/oscript.js new file mode 100644 index 0000000..c946c26 --- /dev/null +++ b/arrivals/oscript.js @@ -0,0 +1,19 @@ +document.addEventListener('DOMContentLoaded', () => { + const headers = document.querySelectorAll('th'); + const headerTexts = [ + ["Orario", "Time"], + ["Compagnia", "Airline"], + ["# Volo", "Flight #"], + ["Provenienza", "Origin"], + ["Informazioni", "Status"] + ]; + + let index = 0; + + setInterval(() => { + headers.forEach((header, i) => { + header.textContent = headerTexts[i][index % headerTexts[i].length]; + }); + index++; + }, 10000); +}); \ No newline at end of file diff --git a/arrivals/ryanair.png b/arrivals/ryanair.png new file mode 100644 index 0000000..c41935f Binary files /dev/null and b/arrivals/ryanair.png differ diff --git a/arrivals/wizzair.png b/arrivals/wizzair.png new file mode 100644 index 0000000..c4f8ab3 Binary files /dev/null and b/arrivals/wizzair.png differ