//
function miniCart(){
var prdCount = 0, prdString = "", subTotal = (xmlConfig.cartSubTotal > 0)?xmlConfig.cartSubTotal:0;
	if(xmlOHeader.childNodes.length==0) subTotal = 0;
	for(var i=0;i<xmlOHeader.childNodes.length;i++){
		prdCount = prdCount+(parseInt(xmlOHeader.childNodes[i].QuantityAmount));
		};
	prdString += "Produkte:<strong>&nbsp;" + prdCount + "</strong><br>";
	prdString += "Summe:<strong>&nbsp;" + TFormatCurrency(subTotal, objPriCurrency) + "</strong><br><br>";
	prdString += "<a class=\"WAGRUNAV\" href=\"orderform." + xmlConfig.fileExtension + "\">";
	prdString += '<img src="assets/images/bulletcat1st.gif" width="13" height="14" alt="Bullet.gif" border="0" align="absmiddle" hspace="0" vspace="0" class="catnav">' + "Zum Bestellschein</a>";
	return(prdString);
	};
//
var TNavDropDownIndent = ".."
//
function NavLinkedDropDownList(){
	return(TNavDropDownList(true));
	};
//
function NavDropDownList(){
	return(TNavDropDownList(false));
	};
//
function storeSearchParameters(optionValueArray){
var xmlSearchEngine = xmlConfig.getFirstItem("SearchEngine");
	if(optionValueArray[0]!="null"&&optionValueArray[0]!="nada"){
		xmlSearchEngine.categoryIndex = optionValueArray[0];
		xmlSearchEngine.categoryId = optionValueArray[2];
		xmlSearchEngine.ByCategory = "1";
		}
	else{
		xmlSearchEngine.categoryIndex = "null";
		xmlSearchEngine.categoryId = "null";
		xmlSearchEngine.ByCategory = "0";
		};
	};
//
function TNavDropDownList(asLink){
var rString = "";
var myNavIndex = "";
	if(asLink) myNavIndex = xmlConfig.navIndex;
	else myNavIndex = xmlConfig.getFirstItem("SearchEngine").categoryIndex;
	if(!(myNavIndex=="null"||myNavIndex=="")){ navigation[parseInt(myNavIndex)].active = true; };
	if(asLink) rString += "<select name=\"navselect\" onChange=\"changeLoc(this[this.selectedIndex].value.split(';;')[0],this[this.selectedIndex].value.split(';;')[1])\">"
	else rString += "<select name=\"navselect\" onChange=\"storeSearchParameters(this[this.selectedIndex].value.split(';;'))\">";
	rString += "<option value=\"nada;;start.htm;;null\">Produkt-Katalog</option>";
	for(var i=0; i<navigation.length; i++){
		if(navigation[i].parentId==null){
			rString += TNavDropDownItem(navigation[i], "");
			};
		};
	rString += "</select>";
	return(rString);
	};
//
function TNavDropDownItem(navItem, cptPreFix){
var rString = "";
	rString += "<option value=\"" + navItem.id + ";;" + navItem.linkUrl + ";;" + navItem.categoryId + "\"";
	if(navItem.active) rString += " selected";
	rString += ">" + cptPreFix + navItem.caption + "</option>";
	for(var i=0; i<navigation.length;i++) if(navigation[i].parentId==navItem.id) rString += TNavDropDownItem(navigation[i], cptPreFix + TNavDropDownIndent);
	return(rString);	
	};
//
	function openItem(itemId){
	var objActiveItem = null;
		if(itemId!=null){
			objActiveItem = navigation[itemId];
			if(objActiveItem!=null){
				objActiveItem.open = true;
				openItem(objActiveItem.parentId);
				};
			};
		};
		
	function activateItem(itemId){
	var objActiveItem = null;
		if(itemId!=null){
			objActiveItem = navigation[itemId];
			if(objActiveItem!=null){
				objActiveItem.active = true;
				openItem(objActiveItem.parentId);
				};
			};
		};
		
	function itemHasSubelems(itemId){
		for(var i=0; i<navigation.length;i++) if(navigation[i].parentId==itemId) return(true);
		return(false);
		};


<!--  24.05.2004: "lenght mit lenght-1" ersetzt damit letzte Warengruppenliste nicht angezeigt wird  -->	
	function TNavLinkList(){
	var strHTML = "";
		for(var i=0; i<navigation.length-1; i++) if(navigation[i].parentId==null) strHTML += printItem(navigation[i], 0);
		return(strHTML);
		};
	
		
	function printItem(navItem, depth){
	var strHTML = "";
	var elemWidth = 1;
		strHTML += '<table width="100%" class="CATLINKS1STPARENT" border="0" cellpadding="1" cellspacing="0" >';
		strHTML += "<tr>"
		for(var i=0; i<depth; i++){
			strHTML += "<td";
			if(navItem.active) strHTML += " class=\"ACTIVECATEGORY\""
			else strHTML += " class=\"CATLINKS1STBULLET\"";
			strHTML += ' width="1%"><img src="assets/images/spacer.gif" width="13" height="1" height="1" alt="" border="0"></td>';
			};
		if(navItem.active) strHTML += '<td width="1%" class="ACTIVECATEGORY"><img src="assets/images/bulletcatact.gif" width="13" height="14" alt="BulletCatAct.gif" border="0" align="bottom" hspace="0" vspace="0" class="catnav"></td>'
		else if(navItem.open&&itemHasSubelems(navItem.id)) strHTML += '<td width="1%" class="CATLINKS1STBULLET"><img src="assets/images/bulletcat1stcls.gif" width="13" height="14" alt="BulletCat1stCls.gif" border="0" align="bottom" hspace="0" vspace="0" class="catnav"></td>'
		else strHTML += '<td width=\"1%\"><img src="assets/images/bulletcat1st.gif" width="13" height="14" alt="BulletCat1st.gif" border="0" align="bottom" hspace="0" vspace="0" class="catnav"></td>'
		strHTML += "<td";
		if(navItem.active) strHTML += " class=\"ACTIVECATEGORY\""
		else strHTML += " class=\"CATLINKS1STBULLET\"";
		strHTML += "width=\"" + ( 100 - ( depth + 1 ) ) + "%\">"
			+ "<a href=\"" + navItem.linkUrl + "?categoryId=" + escape(navItem.id) + "\" class=\"WAGRUNAV\">"
			+ navItem.caption
			+ "</a>"
			+ "</td>";
		strHTML += "</tr>"
		strHTML += "</table>"
		depth++;
		if(navItem.active||navItem.open){
			for(var i=0; i<navigation.length;i++) if(navigation[i].parentId==navItem.id) strHTML += printItem(navigation[i], depth);
			};
		return(strHTML);
		};


//

// navElem
	function navElem(id,caption,linkUrl,parentId,categoryId){
		this.id = id;
		this.caption = caption;
		this.linkUrl = linkUrl;
		this.parentId = parentId;
		this.active = false;
		this.open = false;
		this.categoryId = categoryId;
		};
// navigation
var navigation = new Array();
//
navigation[0] = new navElem(0,"Kataloge/Infoschriften","pi-2079793928.htm",null,"00-100");
navigation[1] = new navElem(1,"Aktuelle Neuheiten","pi-825155691.htm",null,"00-200");
navigation[2] = new navElem(2,"GPS-Geräte","pi-884414257.htm",null,"01");
navigation[3] = new navElem(3,"Outdoor & Freizeit","pi-1514477980.htm",2,"1-100");
navigation[4] = new navElem(4,"Montana","pi1306516259.htm",3,"1-1005");
navigation[5] = new navElem(5,"Zubehör","pi687535912.htm",4,"1-110Z");
navigation[6] = new navElem(6,"Oregon","pi1218723566.htm",3,"1-1010");
navigation[7] = new navElem(7,"Zubehör","pi-353836073.htm",6,"1-1026-Z");
navigation[8] = new navElem(8,"Dakota","pi1249644376.htm",3,"1-1012");
navigation[9] = new navElem(9,"Zubehör","pi-1416117639.htm",8,"1-1012-Z");
navigation[10] = new navElem(10,"GPS 62-Reihe","pi1754463910.htm",3,"1-1050");
navigation[11] = new navElem(11,"Zubehör","pi1579149103.htm",10,"1-1050-Z");
navigation[12] = new navElem(12,"GPS 72/78-Reihe","pi1274177045.htm",3,"1-1080");
navigation[13] = new navElem(13,"Zubehör","pi-993237721.htm",12,"1-1080-Z");
navigation[14] = new navElem(14,"etrex","pi424535014.htm",3,"1-1084");
navigation[15] = new navElem(15,"Zubehör","pi1150248742.htm",14,"1-102-2");
navigation[16] = new navElem(16,"nüvi 550","pi1242295258.htm",3,"1-1090");
navigation[17] = new navElem(17,"Zubehör","pi-293711533.htm",16,"1-1030-Z");
navigation[18] = new navElem(18,"Fahrrad-Navis","pi1131879810.htm",2,"1-130");
navigation[19] = new navElem(19,"Edge 200","pi1395453838.htm",18,"1-65-20");
navigation[20] = new navElem(20,"Edge 500","pi-713759174.htm",18,"1-65-50");
navigation[21] = new navElem(21,"Edge 800","pi1304238006.htm",18,"1-65-80");
navigation[22] = new navElem(22,"Zubehör","pi921893851.htm",18,"1-65-Z");
navigation[23] = new navElem(23,"Sport & Fitness","pi191928604.htm",2,"1-400");
navigation[24] = new navElem(24,"Forerunner","pi1407992414.htm",23,"1-210");
navigation[25] = new navElem(25,"Zubehör","pi1190956025.htm",24,"1-109-1");
navigation[26] = new navElem(26,"Foretrex","pi1079632814.htm",23,"1-220");
navigation[27] = new navElem(27,"Zubehör","pi661013251.htm",26,"1-111-1");
navigation[28] = new navElem(28,"Golf GPS","pi1297252787.htm",2,"1-500");
navigation[29] = new navElem(29,"Zubehör","pi1297507344.htm",28,"1-350-Z");
navigation[30] = new navElem(30,"Strassennavigation","pi-1311221867.htm",2,"2-100");
navigation[31] = new navElem(31,"dezl 560","pi1299314552.htm",30,"1-101");
navigation[32] = new navElem(32,"Zubehör","pi-948832273.htm",31,"1-111-Z");
navigation[33] = new navElem(33,"nüLink","pi1260030453.htm",30,"1-103");
navigation[34] = new navElem(34,"Zubehör","pi2145148434.htm",33,"1-142-Z");
navigation[35] = new navElem(35,"nüvi 465","pi1250323358.htm",30,"1-110");
navigation[36] = new navElem(36,"Zubehör","pi802217671.htm",35,"1-465-Z");
navigation[37] = new navElem(37,"nüvi 550","pi1074728778.htm",30,"1-112");
navigation[38] = new navElem(38,"Zubehör","pi-1211083513.htm",37,"1-450-Z");
navigation[39] = new navElem(39,"nüvi 1390/1490","pi1245490437.htm",30,"1-120");
navigation[40] = new navElem(40,"Zubehör","pi2019354594.htm",39,"1-140-Z");
navigation[41] = new navElem(41,"nüvi 22xx","pi-62244025.htm",30,"1-22");
navigation[42] = new navElem(42,"Zubehör","pi-1190251140.htm",41,"1-220-Z");
navigation[43] = new navElem(43,"nüvi 24xx","pi1300522214.htm",30,"1-24");
navigation[44] = new navElem(44,"Zubehör","pi-226500436.htm",43,"1-24-Z");
navigation[45] = new navElem(45,"nüvi 25xx","pi1322847835.htm",30,"1-25");
navigation[46] = new navElem(46,"Zubehör","pi-288536576.htm",45,"1-25-Z");
navigation[47] = new navElem(47,"nüvi 34xx/37xx","pi-40710222.htm",30,"1-379");
navigation[48] = new navElem(48,"Zubehör","pi-1665499769.htm",47,"1-130-Z");
navigation[49] = new navElem(49,"zümo","pi1157365527.htm",30,"1-850");
navigation[50] = new navElem(50,"Zubehör","pi440041740.htm",49,"1-6000-Z");
navigation[51] = new navElem(51,"Montana","pi-92505761.htm",30,"1-900");
navigation[52] = new navElem(52,"Zubehör","pi-1716736076.htm",51,"1-900-Z");
navigation[53] = new navElem(53,"nüvi-Sets mit Lifetime","pi1302534310.htm",2,"2-110");
navigation[54] = new navElem(54,"Truck-Navis","pi55135412.htm",2,"2-200");
navigation[55] = new navElem(55,"Zubehör","pi399258533.htm",54,"1-15-Z");
navigation[56] = new navElem(56,"Motorrad-Navis","pi335597115.htm",2,"2-250");
navigation[57] = new navElem(57,"Zubehör","pi-486443273.htm",56,"1-500-Z");
navigation[58] = new navElem(58,"Marine-/Wassersport","pi1576485682.htm",2,"3-100");
navigation[59] = new navElem(59,"Handgeräte","pi789480009.htm",58,"2-10");
navigation[60] = new navElem(60,"Kartenplotter","pi-941094640.htm",58,"2-15");
navigation[61] = new navElem(61,"Echolote-Fischfinder","pi1069228535.htm",58,"2-20");
navigation[62] = new navElem(62,"Zubehör Marine GPS","pi-740871438.htm",58,"2-90");
navigation[63] = new navElem(63,"Tracker/Ortung","pi1296982792.htm",2,"3-200");
navigation[64] = new navElem(64,"Zubehör","pi1297511026.htm",63,"1-8-Z");
navigation[65] = new navElem(65,"GPS-Module","pi1080752858.htm",2,"3-400");
navigation[66] = new navElem(66,"Zubehör","pi-491207302.htm",65,"02-100-1");
navigation[67] = new navElem(67,"Strassenkarten","pi1479761874.htm",null,"02");
navigation[68] = new navElem(68,"Strassenkarten CD/DVD","pi1069914197.htm",67,"02-100");
navigation[69] = new navElem(69,"Strassenkarten microSD/SD","pi-1468163843.htm",67,"02-200");
navigation[70] = new navElem(70,"Europa","pi1308385119.htm",69,"02-200-10");
navigation[71] = new navElem(71,"Nordamerika","pi1025469978.htm",69,"02-200-20");
navigation[72] = new navElem(72,"Südamerika","pi2146547347.htm",69,"02-200-22");
navigation[73] = new navElem(73,"Osteuropa","pi64029845.htm",69,"02-200-30");
navigation[74] = new navElem(74,"Naher Osten","pi-53938768.htm",69,"02-200-35");
navigation[75] = new navElem(75,"Nordafrika","pi-1052288121.htm",69,"02-200-37");
navigation[76] = new navElem(76,"Süd-/Ostafrika","pi-1702517430.htm",69,"02-200-38");
navigation[77] = new navElem(77,"Ozeanien","pi-785830935.htm",69,"02-200-50");
navigation[78] = new navElem(78,"Ferner Osten","pi-599951297.htm",69,"02-200-60");
navigation[79] = new navElem(79,"nüMaps Kartenupdates","pi1204366179.htm",67,"02-500");
navigation[80] = new navElem(80,"Freizeit/Wanderkarten","pi1277915137.htm",null,"03");
navigation[81] = new navElem(81,"Schweiz","pi629380654.htm",80,"03-100");
navigation[82] = new navElem(82,"Alpenraum","pi1305350566.htm",80,"03-110");
navigation[83] = new navElem(83,"Deutschland","pi-228542410.htm",80,"03-120");
navigation[84] = new navElem(84,"Oesterreich","pi1306471343.htm",80,"03-130");
navigation[85] = new navElem(85,"Frankreich","pi-1208009455.htm",80,"03-140");
navigation[86] = new navElem(86,"Benelux","pi-1924423287.htm",80,"03-150");
navigation[87] = new navElem(87,"Italien","pi-1405985527.htm",80,"03-160");
navigation[88] = new navElem(88,"Spanien","pi1306342733.htm",80,"03-170");
navigation[89] = new navElem(89,"Dänemark","pi1064773417.htm",80,"03-180");
navigation[90] = new navElem(90,"Norwegen","pi1990702090.htm",80,"03-190");
navigation[91] = new navElem(91,"Schweden","pi1305366574.htm",80,"03-200");
navigation[92] = new navElem(92,"Finnland","pi409946309.htm",80,"03-210");
navigation[93] = new navElem(93,"England","pi1305358205.htm",80,"03-220");
navigation[94] = new navElem(94,"Ireland","pi220373821.htm",80,"03-230");
navigation[95] = new navElem(95,"Osteuropa","pi-158418409.htm",80,"03-300");
navigation[96] = new navElem(96,"Afrika","pi1305886212.htm",80,"03-320");
navigation[97] = new navElem(97,"Nordamerika","pi-395886637.htm",80,"03-340");
navigation[98] = new navElem(98,"Ozeanien","pi613689902.htm",80,"03-360");
navigation[99] = new navElem(99,"Ausland übriges","pi-914558899.htm",80,"03-400");
navigation[100] = new navElem(100,"Seekarten/BlueChart","pi-1012932035.htm",null,"04");
navigation[101] = new navElem(101,"Schweizer Seen","pi647860922.htm",100,"04-100");
navigation[102] = new navElem(102,"Binnengewässer","pi-402266445.htm",100,"04-120");
navigation[103] = new navElem(103,"BlueChart","pi-2079432840.htm",100,"04-200");
navigation[104] = new navElem(104,"g2","pi-1944271052.htm",103,"04-220");
navigation[105] = new navElem(105,"g2 VISION","pi1158134821.htm",103,"04-240");
navigation[106] = new navElem(106,"g2 GARMIN","pi631591042.htm",103,"04-260");
navigation[107] = new navElem(107,"Zubehör GPS","pi1058531655.htm",null,"10");
navigation[108] = new navElem(108,"Travel-Pack/Reiseset","pi1302540570.htm",107,"Z-10");
navigation[109] = new navElem(109,"Schutztaschen/Etui","pi1797354435.htm",107,"Z-20");
navigation[110] = new navElem(110,"Netz-/Ladegeräte","pi2007698573.htm",107,"Z-200");
navigation[111] = new navElem(111,"TMC-Verkehrsfunkempfänger","pi-727650214.htm",107,"Z-250");
navigation[112] = new navElem(112,"ecoRoute HD","pi-93348474.htm",107,"Z-260");
navigation[113] = new navElem(113,"Tracker","pi1296991613.htm",107,"Z-270");
navigation[114] = new navElem(114,"Halterungen","pi-245055049.htm",107,"Z-300");
navigation[115] = new navElem(115,"Touratech Lenkerhalter","pi-1396059407.htm",107,"Z-310");
navigation[116] = new navElem(116,"Speicherkarten","pi1158294733.htm",107,"Z-400");
navigation[117] = new navElem(117,"Helm-Lautsprecher","pi564031940.htm",107,"Z-450");
navigation[118] = new navElem(118,"Antennen","pi-1047934084.htm",107,"Z-470");
navigation[119] = new navElem(119,"Akku & Ladegeräte","pi1730575707.htm",null,"11");
navigation[120] = new navElem(120,"Ladegeräte","pi1067031736.htm",119,"11-100");
navigation[121] = new navElem(121,"Akkus-Batterien","pi-9981530.htm",119,"11-120");
navigation[122] = new navElem(122,"Akku/Batterie Tester","pi-466886018.htm",119,"11-140");
navigation[123] = new navElem(123,"Zubehör alte GPS-Geräte","pi1226743765.htm",null,"20");
navigation[124] = new navElem(124,"nüvi 2xx","pi1247301125.htm",123,"20-100");
navigation[125] = new navElem(125,"nüvi 7x5","pi-1428018173.htm",123,"20-102");
navigation[126] = new navElem(126,"nüvi 86x","pi-1931847344.htm",123,"20-104");
navigation[127] = new navElem(127,"nüvi diverse","pi521610710.htm",123,"20-106");
navigation[128] = new navElem(128,"StreetPilot 26/27/28xx","pi-1195032193.htm",123,"20-110");
navigation[129] = new navElem(129,"StreetPilot 7200/7500","pi23768823.htm",123,"20-122");
navigation[130] = new navElem(130,"StreetPilot c3xx","pi-666591916.htm",123,"20-124");
navigation[131] = new navElem(131,"StreetPilot c5x0","pi1516838853.htm",123,"20-126");
navigation[132] = new navElem(132,"StreetPilot III","pi2030944268.htm",123,"20-128");
navigation[133] = new navElem(133,"Colorado","pi1256987768.htm",123,"20-200");
navigation[134] = new navElem(134,"GPSmap 60","pi1309858844.htm",123,"20-201");
navigation[135] = new navElem(135,"GPSmap 76","pi-1624372694.htm",123,"20-210");
navigation[136] = new navElem(136,"GPS V","pi1760922141.htm",123,"20-220");
navigation[137] = new navElem(137,"Geko","pi1075095108.htm",123,"20-230");
navigation[138] = new navElem(138,"Quest","pi-365201806.htm",123,"20-240");
navigation[139] = new navElem(139,"iQue","pi-879094608.htm",123,"20-260");
navigation[140] = new navElem(140,"GPSmap 276/278","pi1263719103.htm",123,"20-400");
navigation[141] = new navElem(141,"Forerunner-/trex 101/201","pi2026696068.htm",123,"20-500");
navigation[142] = new navElem(142,"Diverse Modelle","pi823071945.htm",123,"20-900");
navigation[143] = new navElem(143,"Funkzubehör","pi1066913880.htm",null,"30");
navigation[144] = new navElem(144,"Frequenz-Handbücher","pi1534341277.htm",143,"30-10");

// getNavElementByCatID
function getNavElementByCatID(categoryId){
	for(var i=0; i<navigation.length; i++){
		if(navigation[i].categoryId==categoryId){
			return(navigation[i]);
			break;
			};
		};
		return(null);
	};
// changeLoc
function changeLoc(id,linkUrl){
	if(id!="nada"){
		xmlConfig.navIndex = id.toString();
		if(xmlConfig.getFirstItem("SearchEngine").ByCategory == "1"){
			if(id=="null") xmlConfig.getFirstItem("SearchEngine").categoryId = "null"
			else xmlConfig.getFirstItem("SearchEngine").categoryId = navigation[id].categoryId;
			xmlConfig.getFirstItem("SearchEngine").categoryIndex = id;
			}
		else{
			xmlConfig.getFirstItem("SearchEngine").categoryId = "null";
			xmlConfig.getFirstItem("SearchEngine").categoryIndex = "null";
			};
		safeData();
		location.href = linkUrl + "?categoryId=" + id.toString();
		};
	};
// searchOnEnterNavi
function searchOnEnterNavi(){
	if(window.event.keyCode==13){
		xmlConfig.getFirstItem('SearchEngine').term=document.searchEngine.searchTerm.value;
		location.href = "search.htm";
		};
	};
// activates entries for categories
activateItem(getParameterFromURL("categoryId"));


