var startHeight; 
var finishHeight; 
var delay; 
var paus=0; 
var counter; 
var div;
if (navigator.userAgent.indexOf('Gecko') != -1) var step=2; else step=3;
var hid = 18; 
	
function toggleFade(obj)	{
	div = obj.parentNode;
	startHeight = obj.parentNode.clientHeight;
	
	finishHeight = obj.parentNode.scrollHeight;
	if (startHeight>hid) { 
	hide(); obj.getElementsByTagName('img')[0].src = "/images/show.png";
	var expiration = new Date();  
	expiration.setYear(expiration.getYear() + 2); 
	document.cookie = obj.id + "=deleted; expires=Thu, 01-Jan-1970 00:00:01 GMT;path=/";

	} else { show(); obj.getElementsByTagName('img')[0].src = "/images/hide.png"; 
	var expiration = new Date(); 
	expiration.setYear(expiration.getYear() - 2); 
	document.cookie = obj.id +"=1;" + expiration.toGMTString() +";path=/";
	}
}

function show() { 
if (div.clientHeight < finishHeight) {
	div.style.height = (div.clientHeight+step)+'px';
} else { div.style.height = finishHeight+'px';  }
if (div.clientHeight < finishHeight) setTimeout( 'show()', paus ) ;
}

function hide() { 
if (div.clientHeight > hid) {
	div.style.height = (div.clientHeight-step)+'px';
} else { div.style.height = hid+'px';  }
if (div.clientHeight > hid) setTimeout( 'hide()', paus ) ;
}	

function showFast(idObj) {
if (document.getElementById(idObj)) { 
var obj = document.getElementById(idObj);
obj.getElementsByTagName('img')[0].src = "/images/hide.png";
div = obj.parentNode;
div.style.height = obj.parentNode.scrollHeight+'px';
}
}

window.onload = function() {


var center = document.getElementById("menudiv").parentNode;
var foo = document.getElementById("made").parentNode.clientHeight;
var top = document.getElementById("sthead").clientHeight;
var htmlh = document.getElementsByTagName("html")[0].clientHeight;
var control = htmlh - top - foo - 28;

if (navigator.userAgent.indexOf('Opera') != -1) control=600;
if (control>center.clientHeight) center.style.height = control + "px";

}

$(document).ready(function(){
    
    $("#happy").click(function () {
      $(this).hide("puff", {}, 1000);
    });


	});

veimmap=true;
shovraz();
function shovraz(){
if (document.getElementById(202)) {
	mapdiv=document.getElementById(202);

if(veimmap){
mapdiv.style.visibility='hidden';
veimmap=false;
}
else{
mapdiv.style.visibility='visible';
veimmap=true;
}

}
}