//
function miniCart(){
var prdCount = 0, prdString = "", subTotal = (xmlConfig.cartSubTotal > 0)?xmlConfig.cartSubTotal:0;
var tmpVariants = "", strVariants = "";
var mbullet = '<img src="/assets/images/bullet.gif" width="11" height="14" alt="Bullet.gif" border="0" align="absmiddle" hspace="0" vspace="0" class="catnav">';
	if(xmlOHeader.childNodes.length==0) subTotal = 0;
	for(var i=0;i<xmlOHeader.childNodes.length;i++){
		prdCount = prdCount+(parseInt(xmlOHeader.childNodes[i].QuantityAmount));
		};
	prdString += "<table border=\"0\" cellpadding=\"0\" cellspacing=\"2\" width=\"100%\">";
		if(prdCount > 0){
		prdString += "<tr>"
			+ "<td colspan=\"2\">"
				+ "<table class=\"BS\" cellpadding=\"2\" cellspacing=\"0\" width=\"100%\">"
						+ "<th class=\"BSHEAD2\" align=\"right\" nowrap=\"true\" width=\"15\">&nbsp;</th>"
						+ "<Th class=\"BSHEAD\" align=\"left\"><strong>Bezeichnung</strong></th>"
						+ "<th class=\"BSHEAD\" align=\"right\" nowrap=\"true\"><strong>Preis</strong></th>"
					+ "</tr>";
				for(var i=0;i<xmlOHeader.childNodes.length;i++){
				tmpVariants = xmlOHeader.childNodes[i].getFirstItem("Internal").variants.split("@");
				if(tmpVariants.length>1){
					for(var j=0;j<tmpVariants.length-1;j++){
						tmpElement = tmpVariants[j].split(";");
						strVariants += "search" + j + "_EQ_" + tmpElement[1] + "_AND_";
						};
					strVariants += "{EOL}";
					};
					prdString += "<tr valign=\"top\">"
						+ "<td class=\"BSBODY2\" align=\"right\" width=\"15\">" + xmlOHeader.childNodes[i].QuantityAmount + "&nbsp;</td>"
						+ "<td class=\"BSBODY\">"
							+ "<a href=\"" + xmlOHeader.childNodes[i].getFirstItem("Internal").address + "?defaultVariants=" + strVariants + "&categoryId=" + xmlOHeader.childNodes[i].getFirstItem("Internal").navIndex + "\">"
							+ xmlOHeader.childNodes[i].Name
						+ "</a></td>"
						+ "<td class=\"BSBODY\" align=\"right\" nowrap=\"true\">" + (parseFloat(xmlOHeader.childNodes[i].PriceGrossLineTotalLC).toFixed(2)).toString().replace('.',',') + "</td>"
						+ "</tr>"  ;
                                                  };

                                         prdString +=  "<tr><td colspan=\"3\"><table width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" border=\"0\">"
                                                + "<tr>"
			                        + "<td class=\"BSFOOTER\" align=\"left\" nowrap=\"true\"><strong>Summe incl. MwSt.:</strong>&nbsp;</td>"
			                        + "<td>&nbsp;</td>"
                                                + "<td class=\"BSFOOTER\" align=\"right\"><strong>&nbsp;" + TFormatCurrency(subTotal, objPriCurrency) + "</strong><td>"
		                                + "</tr>"
                                                + "</table></td></tr>"   ;

	prdString += "</table><br>"
			+ "</td>"
		+ "</tr>" 

		+ "<tr>"
			+ "<td colspan=\"2\"><input name=\"Warenkorb\" type=\"button\" class=\"BUTTONCART\" id=\"Warenkrb\" onClick=\"BB_goToURL('parent','orderform.htm'); return document.MM_returnValue\" value=\"Zum Warenkorb\">"
			+ "</td>"
		+ "</tr>";
	}
	else{
		prdString += "<tr>"
			+ "<td>"
			+ "<TD class=\"INFOTEXT\">Ihr Warenkorb ist leer...</td>"
			+ "</tr>";
		};
	prdString += "</table>";
	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\"></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);
		};
	
	function TNavLinkList(start,end){
        var strHTML="";
                       for(var i=start;i<Math.min(end+1,navigation.length);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="0" 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="20" height="1" height="1" alt="" border="0"></td>';
			};
		if(navItem.active) strHTML += '<td width="1%" class="ACTIVECATEGORY"><img src="assets/images/1x1transpatrent.gif" width="20" 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/1x1transpatrent.gif" width="20" 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/1x1transpatrent.gif" width="20" 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,"BRAUTSCHUHE","pi-1705579512.htm",null,"5100");
navigation[1] = new navElem(1,"ELSA COLOURED SHOES","pi-73251733.htm",0,"9100");
navigation[2] = new navElem(2,"RAINBOW CLUB IVORY (CREME)  ","pi-2011527106.htm",1,"41");
navigation[3] = new navElem(3,"RAINBOW CLUB WHITE (WEISS)","pi1201461595.htm",1,"63");
navigation[4] = new navElem(4,"RAINBOW COUTURE ","pi22553138.htm",1,"3");
navigation[5] = new navElem(5,"ELSE COLLECTION","pi-780517903.htm",1,"4");
navigation[6] = new navElem(6,"ISABELLA COLLECTION","pi1253716868.htm",1,"64");
navigation[7] = new navElem(7,"NINA FIARUCCI","pi2109140683.htm",1,"6");
navigation[8] = new navElem(8,"BRAUTSCHUH SALE","pi1620545345.htm",1,"7");
navigation[9] = new navElem(9,"FAITHFUL","pi1112119387.htm",0,"8");
navigation[10] = new navElem(10,"DORIANI","pi-443323020.htm",0,"50");
navigation[11] = new navElem(11,"EXCLUSIV MODELLE","pi1068128053.htm",0,"9");
navigation[12] = new navElem(12,"BRAUTTASCHEN","pi1066300228.htm",null,"10");
navigation[13] = new navElem(13,"HANDSCHUHE","pi-1533453579.htm",null,"11");
navigation[14] = new navElem(14,"STOLEN & JACKEN","pi1103061041.htm",null,"40");
navigation[15] = new navElem(15,"RINGKISSEN ","pi-505143670.htm",null,"12");
navigation[16] = new navElem(16,"KOPFSCHMUCK","pi1810190347.htm",null,"13");
navigation[17] = new navElem(17,"RAINBOW CLUB KOPFSCHMUCK","pi1869765552.htm",16,"5");
navigation[18] = new navElem(18,"RAINBOW CLUB SCHLEIER","pi761489758.htm",16,"2");
navigation[19] = new navElem(19,"KÄMME & GESTECKE","pi150533104.htm",16,"15");
navigation[20] = new navElem(20,"DIADEME & HAARREIFEN","pi1084125384.htm",16,"16");
navigation[21] = new navElem(21,"CURLIES & HAARNADELN","pi-13794519.htm",16,"17");
navigation[22] = new navElem(22,"SCHLEIER","pi-2036604459.htm",16,"14");
navigation[23] = new navElem(23,"SCHLEIERABSCHLUSS","pi404077479.htm",16,"39");
navigation[24] = new navElem(24,"SCHLEIERGESTECKE","pi1098018252.htm",16,"52");
navigation[25] = new navElem(25,"BRAUTSCHMUCK","pi1949197654.htm",null,"18");
navigation[26] = new navElem(26,"OHRRINGE","pi371307365.htm",25,"20");
navigation[27] = new navElem(27,"HALSKETTEN","pi1119032351.htm",25,"19");
navigation[28] = new navElem(28,"SCHMUCKSETS","pi944921578.htm",25,"53");
navigation[29] = new navElem(29,"JUBILÄUMSSCHMUCK","pi1220619951.htm",null,"49");
navigation[30] = new navElem(30,"WÄSCHE","pi251674968.htm",null,"21");
navigation[31] = new navElem(31,"STRUMPFBÄNDER","pi-257802731.htm",30,"26");
navigation[32] = new navElem(32,"STRÜMPFE","pi-326383694.htm",30,"27");
navigation[33] = new navElem(33,"UNTERRÖCKE","pi1086639966.htm",null,"28");
navigation[34] = new navElem(34,"SONSTIGES","pi376840361.htm",null,"56");
navigation[35] = new navElem(35,"BRAUTKLEIDER","pi1111610129.htm",null,"0");
navigation[36] = new navElem(36,"LADYBIRD und MODE DE POL","pi-126656514.htm",35,"1");
navigation[37] = new navElem(37,"LUXUAR FASHION","pi1668906588.htm",35,"3100");
navigation[38] = new navElem(38,"ABENDKLEIDER","pi-290713880.htm",null,"60");
navigation[39] = new navElem(39,"LUXUAR ","pi1860296237.htm",38,"4100");
navigation[40] = new navElem(40,"ANZÜGE","pi-1004144873.htm",null,"29");
navigation[41] = new navElem(41,"WESTEN","pi1108820801.htm",null,"35");
navigation[42] = new navElem(42,"HEMDEN","pi1080842315.htm",null,"33");
navigation[43] = new navElem(43,"FOCALÉ & KRAWATTE","pi1108823057.htm",null,"36");
navigation[44] = new navElem(44,"MANSCHETTENKNÖPFE","pi2135882503.htm",null,"34");
navigation[45] = new navElem(45,"GÜRTEL","pi1560267493.htm",null,"42");
navigation[46] = new navElem(46,"BRÄUTIGAMSCHUHE","pi-687599343.htm",null,"30");
navigation[47] = new navElem(47,"HAMLET","pi1285814663.htm",46,"31");
navigation[48] = new navElem(48,"ELSA COLOURED SHOES MAN","pi-910022980.htm",46,"32");
navigation[49] = new navElem(49,"BLUMENKÖRBCHEN","pi1137790508.htm",null,"51");
navigation[50] = new navElem(50,"KINDERKOPFSCHMUCK","pi-382218945.htm",null,"55");
navigation[51] = new navElem(51,"KINDERSCHUHE","pi-1742423831.htm",null,"54");
navigation[52] = new navElem(52," AUSLAUFARTIKEL GÜNSTIGER","pi131178877.htm",null,"37");
navigation[53] = new navElem(53,"BRAUTSCHUHE","pi1169330353.htm",52,"43");
navigation[54] = new navElem(54,"BRAUTTASCHEN","pi631403806.htm",52,"44");
navigation[55] = new navElem(55,"HANDSCHUHE","pi-1001944505.htm",52,"45");
navigation[56] = new navElem(56,"RINGKISSEN","pi898570364.htm",52,"46");
navigation[57] = new navElem(57,"KOPFSCHMUCK","pi-1389972019.htm",52,"47");
navigation[58] = new navElem(58,"SCHMUCK","pi1768170250.htm",52,"48");

// 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"));


