// JavaScript Document

var count = .1;
var maxcount = .8; 
var mincount = .1;

var iecount = 10;

function slideformdown() {
	document.getElementById("formcontainer").style.display  = 'block';
	document.getElementById("formslider").style.display  = 'block';
	//document.getElementById("formslider").style.top  = (window.screen.height / 4) + 'px';
	document.getElementById("formslider").style.left  = (window.screen.width / 4) + 'px';
	//Keep on moving the image till the target is achieved
	fadeslidedown();
}

function fadeslidedown() {
	if (count < maxcount) { 
		count += .1;
		iecount += 10;
		document.getElementById("formcontainer").style.opacity = count;
		document.getElementById("formcontainer").style.filter = 'alpha(opacity=' + iecount + ')';
		document.getElementById("formcontainer").style.height = window.screen.height + 'px';
		setTimeout('fadeslidedown()',100);
	} 
}

function slideformup() {
	var count = .8;
	var mincount = .1;
	document.getElementById("formslider").style.display  = 'none';
	//Keep on moving the image till the target is achieved
	fadeslideup();
}

function fadeslideup() {
	if(count > mincount) {
		count -= .1;
		iecount -= 10;
		//Move the image to the new location
		document.getElementById("formcontainer").style.opacity = count;
		document.getElementById("formcontainer").style.filter = 'alpha(opacity=' + iecount + ')';
		setTimeout('fadeslideup()',50);
	} else {
		document.getElementById("formcontainer").style.display  = 'none';
	}
}

