function show_mail(addr) {
	addr = addr.replace(" (a) ", "@");
	addr = addr.replace("(a)", "@");
	location.href = "mailto:"+addr;
/*	address_to_replace = document.getElementById("e").firstChild;
	real_address = address_to_replace.nodeValue.replace("[at]", "@");
	address_to_replace.nodeValue = real_address;
	address_to_replace.parentNode.setAttribute("href", "mailto:"+real_address);*/
}

function copyEUR(value) {
    for (var i = 0; true; i++) {
	var o = document.getElementById('eur'+i);
	if (!o) break;
	o.innerHTML = value;
    }
}

function copyEEK(value) {
    for (var i = 0; true; i++) {
	var o = document.getElementById('eek'+i);
	if (!o) break;
	o.innerHTML = value;	
    }
    var eur = Math.ceil(value / 15.64664);
    document.getElementById('price_eur').value = eur;
    copyEUR(eur);
}

function print_date() {
var currentTime = new Date();
var month = currentTime.getMonth()+1 + "";
var day = currentTime.getDate() + "";
var year = currentTime.getFullYear();
	if (month.length == 1) {
	month = "0" + month;
	}
	if (day.length == 1) {
	day = "0" + day;
	}
document.write(day + "." + month + "." + year);
}

function info(lang,type,w,h){
		if (typeof(w) == "undefined") {
		var w = 400;
			if (type == "euribor") {
			w = 220;
			}
		}
		if (typeof(h) == "undefined") {
		var h = 300;
			if (type == "euribor") {
			h = 280;
			}
			else if (type == "deposit") {
			h = 700;
			}
		}
	var winl = (screen.width-w)/2;
	var wint = (screen.height-h)/2;
	if (winl < 0) winl = 0;
	if (wint < 0) wint = 0;
	var page = '/calc/popup.php?lang='+lang+'&type='+type;
	windowprops = "height="+h+",width="+w+",top="+ wint +",left="+ winl +",location=no,"
	+ "scrollbars=yes,menubars=no,toolbars=no,resizable=no,status=yes";
	window.open(page, "Popup", windowprops);
}