Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <script>
- $(function() {
- function update() {
- document.getElementById("song").innerHTML = '<i class="fas fa-sync fa-spin"></i>';
- jQuery.ajax({
- type: 'GET',
- url: "https://zoneradio.de/ajax/updateSong",
- dataType: "json",
- success: function (d) {
- if (d.islive == 0) {
- if(d.currentSong == "false" || d.currentSong == "null") {
- document.getElementById("song").innerHTML = '<i class="fas fa-sync fa-spin"></i>';
- } else {
- document.getElementById("tag").innerHTML = 'AutoDJ';
- document.getElementById("song").innerHTML = '' + d.currentSong + '';
- document.getElementById("wish").innerHTML = '';
- }
- } else {
- jQuery.ajax({
- type: 'GET',
- url: "https://zoneradio.de/ajax/getShowinfos",
- dataType: "json",
- success: function (n) {
- document.getElementById("tag").innerHTML = 'LIVE';
- document.getElementById("song").innerHTML = n.showname;
- document.getElementById("wish").innerHTML = "- <a href='https://zoneradio.de/musikwunsch' class='white-text'>Jetzt Musikwunsch einsenden <i class='fas fa-arrow-right'></i></a>";
- },
- error:function(n){
- document.getElementById("song").innerHTML = '<i class="fas fa-sync fa-spin"></i>';
- }
- });
- }
- },
- error:function(d){
- document.getElementById("song").innerHTML = '<i class="fas fa-sync fa-spin"></i>';
- }
- });
- }
- setInterval(update, 30000);
- update();
- });
- </script>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement