//	window.onerror = function(msg, url, linenumber) {
//		alert("Error:" + msg + "\nAt line: " + linenumber + "\nIn file: " + url);
//		return true;
//	};
/*  Versione player nella stessa finestra
	Playa.onStateChange = function() {
		sTitle = (Playa.playListPosition+1) + "/" + Playa.playlistSize + " ";
		if (Playa.path == "") {
			sTitle += Playa.title;
		} else {
			sTitle += "<"+"a href=\"" + Playa.path + "\" target=\"_blank\" title=\"Click to download\"" + ">" + Playa.title + "<" + "/a" + ">";
		}

		document.getElementById("songTitle").innerHTML = sTitle;
		document.getElementById("btnPlayStop").value = Playa.btnState;
	}
	
*/	

/*  Versione player in un popup */
	Playa.onStateChange = function() {
		sTitle = (Playa.playListPosition+1) + "/" + Playa.playlistSize + " ";
		if (Playa.path == "") {
			sTitle += Playa.title;
		} else {
	       /*  Versione nel caso che si voglia far scaricare l'mp3
 			sTitle += "<"+"a href=\"" + Playa.path + "\" target=\"_blank\" title=\"Click to download\"" + ">" + Playa.title + "<" + "/a" + ">"; */
			sTitle += Playa.title;
		}
		
		// TODO: fare in modo da poter intercettare in qulaunque pagina aperta (index, portfolio ecc) 
		opener.document.getElementById("songTitle").innerHTML = sTitle;
		opener.document.getElementById("btnPlayStop").value = Playa.btnState;
	
	}
	
	

