	// how many seconds you want between updates of the track info
	var updateInterval = 5;
	
/*	// define the alternate message for the web stream
	var altMsg = "<b>Requests?</b> <font color=\"white\">519.488.69.65</font> or "
				 + "<font color=\"white\"><a href=\"mailto:heydj@wildcatradio.ca\">heydj@wildcatradio.ca</a></font>";
*/
				 
	// this function uses an AJAX request to grab the latest track.
	// (this function made using the tutorial at:   http://www.xul.fr/en-xml-ajax.html)
	function getLatestTrack(varStream) {
		
		var xhr;
		
		// Create the XMLHTTP object (for both IE & non-IE browsers)
		try {
		   xhr = new ActiveXObject("Microsoft.XMLHTTP");    // Trying Internet Explorer 
		}
		catch(e)    // Failed 
		{
		  xhr = new XMLHttpRequest()
		}	
		
		// define the inline callback function
		xhr.onreadystatechange = function() {
			// if the XMLHTTP object is ready:
			if (xhr.readyState == 4) {
				// update the track info if the HTTP server request was successful:
				if (xhr.status == 200) {
					// show the one for the stream if varStream is set
					//if (varStream) {
					//	var tempText = xhr.responseText;
						//document.getElementById("nowPlayingLabel").innerHTML = "Now Playing: ";
					//}
					
					// Show the track text!
					document.getElementById("currTrack").innerHTML = xhr.responseText;
					
				}
			}
		};
		
		// activate the HTTP response
		xhr.open("GET", "webplaylist.txt", true);
		xhr.send(null);
	}

/*	
	// this function shows the alternate message: (for the stream player)
	function showStreamTrack() {
		getLatestTrack();
		document.getElementById("currTrack").innerHTML = "<b style=\"font-weight: bolder\">Now Playing:</b> <span style=\"color:white\">"
														 + document.getElementById("currTrack").innerHTML + "</span>";
	}
*/
	
	// this function is called in the onLoad section of the body to update the track info:
	function startTimerUpdates() {
		// start a looping timer:
		setInterval("getLatestTrack(false)", updateInterval * 10);
	}
	
	// this function is called in the onLoad section of the body to update the track info for the stream:
	function startStreamUpdates() {
		// start a looping timer:
		setInterval("getLatestTrack(true)", updateInterval * 10);
	}
	
/*	
	// this function is called in the onLoad section of the stream player to update the track info:
	function startStreamUpdates() {
		// start a looping timer:
		setInterval("getLatestTrack()", updateInterval * 10);
		// start a looping timer:
		setInterval("showAltMsg()", updateInterval + (0.7 * updateInterval) * 10);
	}
*/