function centerOpenTag() {
	if (screen.width>900)
	{	
		document.write("<div id='page-container'>")
		document.write("<div class='mainbg'>")
	}
	else
	{
		document.write("<div>")
		document.write("<div>")	
	}
}

function centerCloseTag() {
	document.write("</div>")
	document.write("</div>")	
}

function onResize() {
	window.onresize = function() {
	var w = document.body.offsetWidth;
	var f = document.getElementById('page-container');
	if (w < 968) { // the movie is taller than the window - don't try to centre it vertically
	f.style.marginLeft = '0px';
	f.style.left = '0%';
	} else {
	f.style.marginLeft = '-490px';
	f.style.left = '50%';
	}
	};
}



