function vergroessern(pfad, breite, hoehe, id) {
	var x = Math.floor((screen.width  - breite) / 2);
	var y = Math.floor((screen.height - hoehe ) / 2);
	return _allg_pop_oeffnen(pfad, breite, hoehe, x, y, id);
}

function pop_oeffnen_scroll(pfad, w, h) {
	return _allg_pop_oeffnen(pfad, w, h, 20, 20, "einscrollpopup", "yes");
}

function pop_oeffnen(pfad, w, h) {
	return _allg_pop_oeffnen(pfad, w, h, 20, 20, "einpopup", "no");
}

// Vergrößerung Holz
function pop_oeffnen_holz(pfad, w, h) {
	return _allg_pop_oeffnen("pop_bild.php?pfad=" + pfad + "&w=" + w + "&h=" + h, w, h, 20, 20, "popupholz", "no");
}

// Allg. Vergrößerung
function pop_oeffnen_allg(pfad, w, h, id) {
	return _allg_pop_oeffnen("pop_bild.php?pfad=" + pfad + "&w=" + w + "&h=" + h, w, h, 20, 20, id, "no");
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
 window.open(theURL,winName,features);
}

function _allg_pop_oeffnen(pfad, w, h, x, y, id, scroll) {
	_allg_pop_oeffnen_win = window.open(pfad, id, "left=" + x + ",top=" + y + ",width=" + w + ",height=" + h + ",scrollbars=" + scroll + ",resizable=yes");
	_allg_pop_oeffnen_win.focus();
	return false;
}

function UnCryptMailto(s) {
		var shift = 2;
		var n = 0;
		var r = "";
		for(var i = 0; i < s.length; i++) {
			n = s.charCodeAt(i);
			if (n >= 8364) {
				n = 128;
			}
			r += String.fromCharCode(n - (shift));
		}
		return r;
}

function linkTo_UnCryptMailto(s)	{
	location.href = UnCryptMailto(s);
}
