Need some help with a album art script for azuracast. My script works but i want to get the image file, now i only get the url of the image.
var nowPlayingTimeout;
var nowPlaying;
function loadNowPlaying() {
$.ajax({
cache: false,
dataType: "json",
url: 'https://demo.azuracast.com/api/nowplaying/1.',
success: function(np) {
nowPlaying = np;
$('.current-album span').text("" + np.now_playing.song.art);
nowPlayingTimeout = setTimeout(loadNowPlaying, 15000);
}
}).fail(function() {
nowPlayingTimeout = setTimeout(loadNowPlaying, 30000);
});
}
$(function() {
loadNowPlaying();
});
the code seems to be for text only