setInterval("getSongs()",111000);

// Define the callback function
function useData(jsonData) {
	var thisHTML = '';
	for(i=0;i<10;i++) {
	thisHTML = thisHTML + '<a href="' + jsonData.recenttracks.track[i].url.$ + '" target="_blank">' + jsonData.recenttracks.track[i].artist.$ + ' - ' + jsonData.recenttracks.track[i].name.$ + '</a> <span class="small">(' + jsonData.recenttracks.track[i].date.$ + ')</span><br>' ;
	}
	document.getElementById('lastfmcontent').innerHTML = thisHTML;
	document.getElementById('left2').style.display = '';
	bObj.removeScriptTag(); 
}

function getSongs() {
// The web service call
var req  = 'http://www.roolio.com/xmljson.php?page=http://ws.audioscrobbler.com/1.0/user/JackGasoline/recenttracks.xml'; 
// Create a new request object
bObj = new JSONscriptRequest(req); 
// Build the dynamic script tag
bObj.buildScriptTag(); 
// Add the script tag to the page
bObj.addScriptTag();
}

