// JavaScript Document

function fieldFocus(elem, val) {
	if (elem.value == val) {
		elem.value = '';
	}
}
function fieldBlur(elem, val) {
	if (elem.value == '') {
		elem.value = val;
	}
}
function place(id, x, y) {
	if(document.getElementById(id)) {
		document.getElementById(id).style.left = x + 'px';
		document.getElementById(id).style.top = y + 'px';
	}
}
function hide(id) {
	if(document.getElementById(id)) {
		document.getElementById(id).style.display = 'none';
	}
}
function show(id) {
	if(document.getElementById(id)) {
		document.getElementById(id).style.display = 'block';
	}
}
function showJommmy(source, path) {
	if(document.getElementById('jommmyimage')) {
		document.images['jommmyimage'].src = path;
		place('jommmyimage', findPosX(source) + 20, findPosY(source) - 120);
		show('jommmyimage');
		document.getElementById('jommmyimage').style.width = '50px';
		document.getElementById('jommmyimage').style.Height = '50px';
	}
}
function hideJommmy(pfad) {
	if(document.getElementById('jommmyimage')) {
		hide('jommmyimage');
		document.images['jommmyimage'].src = pfad;
	}
}
function findPosY(obj) {
	var curtop = 0;
	if (obj.offsetParent) {
		while (obj.offsetParent) {
			curtop += obj.offsetTop
			obj = obj.offsetParent;
		}
	} else if (obj.y)
		curtop += obj.y;
	return curtop + 15;
}
function findPosX(obj) {
	var curleft = 0;
	if (obj.offsetParent) {
		while (obj.offsetParent) {
			curleft += obj.offsetLeft
			obj = obj.offsetParent;
		}
	} else if (obj.x)
		curleft += obj.x;
	return curleft + 15;
}
function secm() {
	document.write("<a href=\"ma");	
	document.write("ilto");	
	document.write(":");
	secmm();
	document.write("\">");
	secmm();
	document.write("</a>");
	
}
function secmm() {
	document.write("in");	
	document.write("fo");	
	document.write("@");	
	document.write("hei");	
	document.write("zungs");	
	document.write("filter");	
	document.write(".");	
	document.write("de");	
}
