// JavaScript Document

// --------------------------------------------Produktauswahl---------------------------------------

function chooseproduct() 
{
if (document.jsnavigation.targets.options[document.jsnavigation.targets.selectedIndex].value!="")
{
var x;
x = document.jsnavigation.targets.options[document.jsnavigation.targets.selectedIndex].value;
window.open(x, '_blank', 'width=640, height=480, resizable=yes, status=yes, scrollbars=yes');
}
else
{
return false;
}
}

// --------------------------------------------Länderauswahl---------------------------------------

function choosecountry() 
{
if (document.jsnavigation2.targets.options[document.jsnavigation2.targets.selectedIndex].value!="")
{
window.location=document.jsnavigation2.targets.options[document.jsnavigation2.targets.selectedIndex].value
}
else
{
return false;
}
}
// --------------------------------------------Formularprüfung_Kontakt---------------------------------------
function formcheck()
{
	var error = "" ;
	var errortxt = "Bitte füllen Sie die folgenden Formularfelder aus:\n \n";

	if (document.getElementById("Anrede").selectedIndex <= 0)
		error += "- Anrede \n";

	if (document.getElementById("Vorname").value=="")
		error += "- Vorname \n";

	if (document.getElementById("Nachname").value=="")
		error += "- Nachname \n";

	if (document.getElementById("E-mail").value=="")
		error += "- E-Mail Adresse \n";

	if ((document.getElementById("Nachricht").value=="") || (document.getElementById("Nachricht").value=="Geben Sie hier Ihre Nachricht ein."))
		error += "- Nachricht \n";

	if (error != "")
	{
		alert(errortxt += error);
		return false;
	}
	
	return true;
}

// --------------------------------------------Formularprüfung_Proben---------------------------------------
function formcheck2()
{
	var error = "" ;
	var errortxt = "Bitte füllen Sie die folgenden Formularfelder aus:\n \n";

	if (document.getElementById("Probenformular_Anrede").value=="")
		error += "- Ihre Anrede \n";

	if (document.getElementById("Probenformular_Vorname").value=="")
		error += "- Ihr Vorname \n";

	if (document.getElementById("Probenformular_Nachname").value=="")
		error += "- Ihr Nachname \n";

	if (document.getElementById("Probenformular_Strasse").value=="")
		error += "- Ihre Straße \n";

	if (document.getElementById("Probenformular_Nr").value=="")
		error += "- Ihre Hausnummer \n";

	if (document.getElementById("Probenformular_PLZ").value=="")
		error += "- Ihre PLZ \n";

	if (document.getElementById("Probenformular_Wohnort").value=="")
		error += "- Ihr Wohnort \n";

	if (document.getElementById("Probenformular_Land").selectedIndex <= 0)
		error += "- Ihr Land \n";

	if (document.getElementById("Probenformular_Email").value=="")
		error += "- Ihre E-Mail Adresse \n";

	if (error != "")
	{
		alert(errortxt += error);
		return false;
	}
	
	return true;
}
