function init() {
	browserCheck();
	setInterval('changeSize()', 50);
}

function browserCheck(){
	var user_Agent = navigator.userAgent.toLowerCase();
	this.ie = (user_Agent.indexOf("msie") != -1);
}

function changeSize() {
	if(ie){
		windowWidth = document.documentElement.clientWidth;
		windowHeight = document.documentElement.clientHeight;
	}
	else{
		windowWidth = window.innerWidth;
		windowHeight = window.innerHeight;	
	}
	if(windowWidth < 1000){
		document.getElementById("footer").style.width = "1000px";
	}
	else{
		document.getElementById("footer").style.width = "100%";
	}
	
	if(windowHeight <= 600){		
		document.getElementById("footer").style.bottom = (windowHeight+document.body.scrollTop-600)+"px";
	}
	else{
		document.getElementById("footer").style.bottom = "0px";
	}
	if( windowHeight <= 600 ){
		document.getElementById("content").style.margin = "20px 0 0 120px";
	}	
	else if( (windowHeight > 600) && (windowHeight < 790) ){
		var marginTop = ((windowHeight-600)*(50/140))+20;
		document.getElementById("content").style.margin = marginTop+"px 0 0 120px";
	}
	else if( windowHeight > 790 ){
		document.getElementById("content").style.margin = "90px 0 0 120px";
	}
}

var timer;

function showlayer(){
	document.getElementById("menue").style.visibility = "visible";
	document.getElementById("menue").style.display = "block";
	if(timer){
		clearTimeout(timer);
	}
}
	
function hidelayer(){
	timer = window.setTimeout("hide()",100);
}

function hide(){
	document.getElementById("menue").style.visibility = "hidden";
	document.getElementById("menue").style.display = "none";				
}