var openDiv = null;
var last = '';

function showDiv(object, width, height) {
	scroll(0, 0);
	//centrar o popup na horizontal
	if(window.innerWidth) {
		document.getElementById(object).style.left = ((window.innerWidth / 2) - (width / 2)) + 'px';
	} else {
		document.getElementById(object).style.left = ((document.body.offsetWidth / 2) - (width / 2)) + 'px';
	}
	
	
	document.getElementById(object).style.top = '220px';
	
	document.getElementById('overlay').style.display = 'block';
	document.getElementById(object).style.display = 'block';
	
	openDiv = object;
}

function hideDiv(object) {
	document.getElementById(object).style.display = 'none';
	document.getElementById('overlay').style.display = 'none';
	openDiv = null;
}