You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

31 lines
883 B

import QtQuick 2.0
Item {
property string theShow: ""
function getShow(url) {
let request = new XMLHttpRequest()
request.onreadystatechange = function () {
if (request.readyState === XMLHttpRequest.DONE) {
// let content = request.response.slice(0, request.response.indexOf("\n"));
let response = {
status : request.status,
headers : request.getAllResponseHeaders(),
content : request.response
};
};
theShow = request.responseText.toString().slice(0, request.response.indexOf("\n"));
}
request.open("GET", "http://app.radiotangra.com/TMR_monitor_songs")
request.send()
}
Timer {
interval: 30000
running: true
repeat: true
onTriggered: getShow()
}
}