function displayContent(data, textStatus) {
  // data could be xmlDoc, jsonObj, html, text, etc...
	$('#overlay').fadeIn('fast');
	$('#playerbox').fadeOut('fast');
	document.getElementById('overlay-box-content').innerHTML = data;
  this; // the options for this ajax request
}
function displayBox(url) {
	$('#overlay').fadeIn('fast', function() {
	$('#overlay-box').fadeIn('fast')});
	$.get(url, displayContent);		
}

function contactResponseReceived(data) {
	alert(data);
}


function submitContactForm() {
	frm = document.forms['contact'];
	var params = {};
	$('#frmContact')
	.find("input[@checked], input[@type='text'], input[@type='hidden'], input[@type='password'], input[@type='submit'], option[@selected], textarea")
	.filter(":enabled")
	.each(function() {
		params[ this.name || this.id || this.parentNode.name || this.parentNode.id ] = this.value;
	});
	$('#spinner').fadeIn('fast');
	alert(params);
	$.post(frm.getAttribute("action") + "?call=ajax", params, function(xml){
		$('#spinner').fadeOut('fast');
		contactResponseReceived(xml);
	});
	return false;
}

