// javascript DHMTL - funktionen
// author: alexander stier, cuti & stier gbr
// datum: 09.08.2004

var isW3C = (document.getElementById) ? true : false;
var isAll = (document.all) ? true : false; 

function myFunc(elemID) {
    var elem = (isW3C) ? document.getElementById(elemID) : ((isAll) ? document.all[elemID] : null);
    if (elem) {
        // act on element
    }
}

function rollover(Bild)
{
	with (document.images[Bild])
	src = (src.indexOf("0") != -1) ? src.replace(/0/, "1") : src.replace(/1/, "0");
}

function openPopUp(url,name,top,left,width,height,scrollbars,toolbar,status,location)
{
	thirdParameter = 'top=' + top + ',left=' + left + ',width=' + width + ',height=' + height + ',scrollbars=' + scrollbars + ',toolbar=' + toolbar + ',status=' + status + ',location=' + location + ',resizable=1,menubar=no';
	openpUpObj = window.open(url,name,thirdParameter);
	openpUpObj.focus();
}

function validateForm(form)
{
	if (form.inh4.value == "")
	{ alert("Bitte geben Sie Ihren Namen an !"); form.inh4.focus(); return false; }

	if (form.inh11.value == "")
	{ alert("Bitte geben Sie Ihre e-mail-Adresse an !"); form.inh11.focus(); return false; }
	if (form.inh11.value.indexOf('@', 0) == -1 ||	form.inh11.value.indexOf('.', 0) == -1)
	{ alert("Bitte geben Sie ein gültige e-mail-Adresse an !"); form.inh11.focus(); return false; }

	window.open('http://www.cutiundstier.de/images/spacer.gif','mailform','dependent=yes,directories=no,height=450,width=550,left=50,top=50,location=no,menubar=no,titlebar=no,toolbar=no,resizeable=no,scrollbars=auto');

	return true;
}

function toggleContainer(self,id){
	if (document.getElementById(id).style.display == 'none') {
		document.getElementById(id).style.display = 'block';
		self.className = 'menuPoint1b';
	} else {
		document.getElementById(id).style.display = 'none' ;
		self.className = 'menuPoint1a';
	}
}