﻿// JScript-Datei

function popWindow (url,name,params) {
//fuer Fenster die auf onlick in einem a href aufgehen
    pwin=window.open(url, name, params);
    pwin.focus();
    return false;
}

function openPopupUnternehmensgruppe() {
    var popupUnternehmensgruppe = window.open("http://www.nestle.de/corporate/Templates/Pages/unternehmensgruppe.html","unternehmensgruppePopup","width=355,height=370,resizable=no,scrollbars=no,location=no,directories=no,status=no,menubar=no,toolbar=no");
    popupUnternehmensgruppe.focus();
}

function toggleFaqItem(id) {
	$("div.FaqItem").not(id).hide();
	$(id).toggle(); 
	return false;
}

function toggleBreedType(num)
{
	switch( num)
	{
		case "1":
			$('#DogBreeds').show();
			$('#CatBreeds').hide();
			
			$('#CatRace2Panel').hide();
			$('#CatRace3Panel').hide();
			$('#CatBreeds select').val("");
			break;
		case "2":
			$('#DogBreeds').hide();
			$('#CatBreeds').show();
			
			$('#DogRace2Panel').hide();
			$('#DogRace3Panel').hide();
			$('#DogBreeds select').val("");
			break;
		case "3":
			$('#DogBreeds').show();
			$('#CatBreeds').show();
			break;
	}
}

function toggleBreedPanels(race, num) {
	var panel1 = $('#' + race + 'Race1Panel');
	var panel2 = $('#' + race + 'Race2Panel');
	var panel3 = $('#' + race + 'Race3Panel');

	switch(num) {
	case "1":
			panel1.show();
			panel2.hide();
			panel3.hide();
			
			$('#' + race + 'Race2Panel select').val("");
			$('#' + race + 'Race3Panel select').val("");
		break;
	case "2":
			panel1.show();
			panel2.show();
			panel3.hide();
			
			$('#' + race + 'Race3Panel select').val("");
		break;
	case "3":
			panel1.show();
			panel2.show();
			panel3.show();
		break;				
	}
}
