var browserName = navigator.appName; 
var browserVer = parseInt(navigator.appVersion);
var errfound = false;

function anim(id, imageURL) {
	if (timg != id) {
		imageURL = "images/" + lang + "/buttons/" + imageURL + ".gif";
		if (document.layers) {
			document['pic_'+id].src = imageURL == 'none' ? null : imageURL;
			}
		else if (document.all) {
			document.all['pic_'+id].src = imageURL == 'none' ? 'none' : imageURL;
			}
		else if (document.getElementById) {
			document.getElementById('pic_'+id).src = imageURL == 'none' ? 'none' : imageURL;
			}
		}
	}

function aktiv(id, imageURL) {
	if (timg != id) {
		imageURL = "images/" + lang + "/buttons/" + imageURL + ".gif";
		if (document.layers) document['pic_'+id].src = imageURL == 'none' ? null : imageURL;
		else if (document.all) document.all['pic_'+id].src = imageURL == 'none' ? 'none' : imageURL;
		else if (document.getElementById) document.getElementById('pic_'+id).src = imageURL == 'none' ? 'none' : imageURL;
		timg = id;

		for (var i=0; i<anzahl; i++) { 
		imageURL = "images/" + lang + "/buttons/nav_" + i + ".gif";
			if (i != id) {
				if (document.layers) document['pic_'+i].src = imageURL == 'none' ? null : imageURL;
				else if (document.all) document.all['pic_'+i].src = imageURL == 'none' ? 'none' : imageURL;
				else if (document.getElementById) document.getElementById('pic_'+i).src = imageURL == 'none' ? 'none' : imageURL;
				}
			}
		}
	}

function openwindow(theURL,winName,features) {
	newWindow = window.open(theURL,winName,features)
	if (!newWindow.opener) {
		newWindow.opener = window
		}
	newWindow.focus()
	}

function error(elem, text) {
	if (errfound) return;
	window.alert(text);
	elem.select();
	elem.focus;
	errfound = true;
	}
	
function showhide(obj) {
	for (i=0; i<3; i++) {
		if (LayArr[i]!=obj) parent.frames['content'].document.getElementById(LayArr[i]).style.visibility = 'hidden' == 'none' ? 'none' : 'hidden';
//		else show(LayArr[i]);
		}
	}

function show(obj) {
	if (document.layers) {
		parent.frames['content'].document.layers[obj].visibility = 'show' == 'none' ? null : 'show';
		}
	else if (document.all) {
		parent.frames['content'].document.all[obj].style.visibility = 'visible' == 'none' ? 'none' : 'visible';
		}
	else if (document.getElementById) {
//		showhide(obj);
		parent.frames['content'].document.getElementById(obj).style.visibility = 'visible' == 'none' ? 'none' : 'visible';
		}
	}

function hide(obj) {
	if (document.layers) {
		parent.frames['content'].document.layers[obj].visibility = 'hide' == 'none' ? null : 'hide';
		}
	else if (document.all) {
		parent.frames['content'].document.all[obj].style.visibility = 'hidden' == 'none' ? 'none' : 'hidden';
		}
	else if (document.getElementById) {
		parent.frames['content'].document.getElementById(obj).style.visibility = 'hidden' == 'none' ? 'none' : 'hidden';
		}
	}
