

		function SMShop_noDataAvailable(args){
		var $SMS = args[0], _id = $SMS.id, _xml = null;
			// no data available during init
			_xml = SMSession.getSession(_id);
			if(_xml==null) _xml = SMSession.xml.createNode(_id);
			if(_xml!=null) $SMS.xml = _xml;
			};

		function SMBasket_noDataAvailable(args){
		var $SMB = args[0], $SMS = $SMB.parent,
				_doc = $SMS.xml.ownerDocument, _id = $SMB.id, _xml = null;
			// no data available during init
			_xml = $SMS.xml.appendChild(_doc.createNode(_id));
			if(_xml!=null) $SMB.xml = _xml;
			};

		function SMShipMethodInfo_noDataAvailable(args){
		var _SMShipMethodInfo = args[0], $SMB = _SMShipMethodInfo.parent,
				_doc = $SMB.xml.ownerDocument, _id = _SMShipMethodInfo.id, _xml = null;
			// no data available during init
			_xml = $SMB.xml.appendChild(_doc.createNode(_id));
			if(_xml!=null) _SMShipMethodInfo.xml = _xml;
			};

		function SMPayMethodInfo_noDataAvailable(args){
		var _SMPayMethodInfo = args[0], $SMB = _SMPayMethodInfo.parent,
				_doc = $SMB.xml.ownerDocument, _id = _SMPayMethodInfo.id, _xml = null;
			// no data available during init
			_xml = $SMB.xml.appendChild(_doc.createNode(_id));
			if(_xml!=null) _SMPayMethodInfo.xml = _xml;
			};

		function SMGDiscounts_noDataAvailable(args){
		var _SMGDiscounts = args[0], $SMB = _SMGDiscounts.parent,
				_doc = $SMB.xml.ownerDocument, _id = _SMGDiscounts.id, _xml = null;
			// no data available during init
			_xml = $SMB.xml.appendChild(_doc.createNode(_id));
			if(_xml!=null) _SMGDiscounts.xml = _xml;
			};

		function SMProduct_noDataAvailable(args){
		var $SMP = args[0], $SMS = $SMP.shop, _id = $SMP.id, _xml = null;
			// no data available during init
			_xml = $SMS.xml.ownerDocument.createNode(_id);
			if(_xml!=null){
				$SMP.xml = _xml;
				};
			};

		function SMDiscounts_noDataAvailable(args){
		var _SMDiscounts = args[0], $SMP = _SMDiscounts.parent,
				_doc = $SMP.xml.ownerDocument, _id = _SMDiscounts.id, _xml = null;
			// no data available during init
			_xml = $SMP.xml.appendChild(_doc.createNode(_id));
			if(_xml!=null) _SMDiscounts.xml = _xml;
			};

		function SMVariants_noDataAvailable(args){
		var _SMVariants = args[0], $SMP = _SMVariants.parent,
				_doc = $SMP.xml.ownerDocument, _id = _SMVariants.id, _xml = null;
			// no data available during init
			_xml = $SMP.xml.appendChild(_doc.createNode(_id));
			if(_xml!=null) _SMVariants.xml = _xml;
			};

		function SMShop_onAfterUpdate(args){
		var $SMS = args[0], _id = $SMS.id, _xml = $SMS.xml;
			// after shop update update and save session object
			SMSession.setSession(_id, "xmlnode", _xml);
			SMSession.save();
			};

		function SMBasket_onBeforeReset(args){
			// before resetting basket confirm
			return(confirm("Are you sure to delete your shopping cart? Sind Sie sicher, dass Sie Ihren Warenkorb löschen möchten?"));
			};

		function SMBasket_onAfterReset(args){
			// after resetting basket reload
			location.replace(location.href);
			};

		function SMBasket_onBeforeAdd(args){
		var $SMB = args[0], $SMP = args[1], $SMS = $SMB.parent, _frm = null,
				_elem = null, _params = new Array(), _msg = "";
			// before adding a product, check whether another order
			// has been completed earlier
			if($SMS.getAttribute(_SMAOComplete)=="true"){
				$SMS.reinitOrder();
				};
			return(true);
			};

		function SMProduct_onBeforeUpdate(args){
		var $SMP = args[0], _index = 0, _frm = _elem = _params = null;
			_frm = document.forms["PD" + $SMP.getAttribute(_SMAUniqueID) + "variants"];
			if(_frm!=null&&($SMP.variants.xml.childNodes.length()==0||$SMP.getAttribute("s-var")=="1")){
				_params = new Array();
				for(var i=0; i<_frm.elements.length; i++){
					_index = _frm.elements[i].selectedIndex;
					if(_index<0) _index = 0;
					_elem = _frm.elements[i].options[_index];
					_params[_params.length] = _elem.text;
					_params[_params.length] = _elem.value;
					};
				$SMP.variants.newSimpleVariant.apply($SMP.variants, _params);
				};
			return(true);
			};

		function SMProduct_onAfterUpdate(args){
		var $SMP = args[0], $min = $max = $amnt = 0, $update = false;
			$min = parseInt($SMP.getAttribute(_SMAMinAmount));
			$max = parseInt($SMP.getAttribute(_SMAMaxAmount));
			$amnt = parseFloat($SMP.getAttribute(_SMAAmount));
			if($amnt < $min){
				$amnt = $min; $update = true;
				} else if($max > 0 && $amnt > $max){
				$amnt = $max; $update = true;
				};
			if($update){
				$SMP.setAttribute(_SMAAmount, $amnt);
				$SMP.update();
				};
			};

		function SMBasket_onAfterAdd(args){
		var $SMB = args[0], $SMP = args[1];
			
			alert("The article was added to your shopping cart. Der Artikel wurde dem Warenkorb hinzugefügt! ".replace("&nbsp;", " "));
			
			};

		function SMBasket_onItemExists(args){
		var $SMB = args[0], _SMNewProduct = args[1], _SMExistingProduct = args[2];
			// item exists in basket, return action flag
			// * _eSMReplace	: replace existing item 
			// * _eSMAdd			: add to basket
			// * _eSMCancel		: cancel action
			alert("This product is already in your shooping cart, the product data will be refreshed! Dieses Produkt befindet sich bereits im Warenkorb, die Produktdaten werden aktualisiert! ".replace("&nbsp;", " "));return(_eSMReplace);
			};

		function SMBasket_onBeforeRemove(args){
		var $SMB = args[0], $SMP = args[1], $msg = "Are you sure to remove the product '%d' with the product ID '%n' from your shopping cart? Sind Sie sicher, dass Sie das Produkt '%d' mit der Artikelnummer '%n' aus dem Warenkorb entfernen möchten? ";
			// before removing a product confirm
			$msg = $msg.replace("%d", $SMP.name);
			$msg = $msg.replace("%n", $SMP.getAttribute(_SMACode));
			return(confirm($msg));
			};

		function SMBasket_onAfterRemove(args){
			// reload page after deleting a product;
			location.replace("warenkorb.htm");
			};

		function SMShipMethodInfo_onAfterUpdate(args){
			// update SMShop after recalculating the shipment costs
			SMShop.update();
			};

		function SMPayMethodInfo_onAfterUpdate(args){
			// update SMShop after recalculating the payment costs
			SMShop.update();
			};

		function SMShop_variantSelectionChanged(args){
		var $SMP = args[0], _form = args[1], _varset = _vartext = "", _index = 0, _elem = null;
			_elem = document.getElementById("variant_not_found");
			if(_elem!=null) _elem.style.display = "none";
			// update product variant properties after changes occured in
			// the variants html form
			if($SMP.variants.xml.childNodes.length()!=0){
				for(var i=0; i<_form.elements.length; i++){
					_elem = _form.elements[i];
					_index = _elem.options.selectedIndex;
					if(_index<0) _index = 0;
					if(_varset!="") _varset += ";";
					if(_vartext!="") _vartext += ",";
					_varset += _elem.options[_index].value;
					_vartext += (_elem.options[_index].text).replace(/,/g, "&comma;");
					};
				$SMP.variants.activateByValues(_varset, _vartext);
				$SMP.update();
				displayProductProperties($SMP);
				};
			};

		function SMShop_onBasketGUIElemChanged(args){
		var $SMS = args[0], _elem = args[1], index = args[2], _form = null, _name = "", $SMP = null, _uniqueID = "", _variantID = "";
			// update product amount after changes occured in the
			// basket graphical user interface
			if(_elem!=null){
				_name = _elem.id.replace("PD", "");
				_name = _name.replace("Amount", "");
				if(_name.indexOf("-")){
					_uniqueID = _name.split("-")[0];
					_variantID = _name.split("-")[1];
					}
				else _uniqueID = _name;
				if(index>=0){
					$SMP = $SMS.basket.getProductByIndex(index);
					}
				else if(_variantID!=""){
					$SMP = $SMS.basket.getProductById(_uniqueID, _variantID);
					}
				else $SMP = $SMS.basket.getProductById(_uniqueID);
				if($SMP!=null){
					$SMP.setAttribute(_SMAAmount, _elem.value);
					$SMP.update();
					$SMS.basket.update();
					};
				};
			};

		function SMVariants_onAfterActivate(args){
		var _SMVariants = args[0];
			// update form controls, if any
			_SMVariants.refreshFormControls();
			};

		/* sm:broker-ssl begin-edit */
		var useSSLForCheckout = false;
		var sharedSSLURL = "";
		/* sm:broker-ssl end-edit */

		var sPHPSessionUrl = "";
		
		sPHPSessionUrl = (sharedSSLURL==""?SMOMAbsoluteRootURL + "/phpsession.php":"");
		

		var SMFirstInit = false;
		var SMSession = new SXMLSessionManager(sPHPSessionUrl);
		SMFirstInit = SMSession.init("E452SMV7I0");

		var SMShop = new cSMShop("SMShop");SMShop.init();
		with(SMShop){
		// set basic data
			setAttribute(_SMAInGross, 1); // Gross Prices Entered (0,1)
			setAttribute(_SMAOutGross, 1); // Display Gross Prices (0,1)
			setAttribute(_SMARoundTo, 0); // Round Final Amount (100,50,10,5,0)
			setAttribute(_SMAMinAmount, 0);
			regions[0] = new Array(0, "DE", "Deutschland", 0, 0, 0, 0, true, false, 1, "^DE[ ]{0,1}[0-9]{9}$");
			regions[1] = new Array(1, "AT", "Österreich", 0, 0, 0, 0, false, false, 1, "^AT[ ]{0,1}U[0-9]{8}$");
			regions[2] = new Array(2, "CH", "Schweiz", 0, 0, 0, 0, false, false, 0, "");
			regions[3] = new Array(3, "AF", "Afghanistan", 0, 0, 0, 0, false, false, 0, "");
			regions[4] = new Array(4, "AX", "Åland", 0, 0, 0, 0, false, false, 0, "");
			regions[5] = new Array(5, "AL", "Albania", 0, 0, 0, 0, false, false, 0, "");
			regions[6] = new Array(6, "DZ", "Algeria", 0, 0, 0, 0, false, false, 0, "");
			regions[7] = new Array(7, "AS", "American Samoa", 0, 0, 0, 0, false, false, 0, "");
			regions[8] = new Array(8, "AD", "Andorra", 0, 0, 0, 0, false, false, 0, "");
			regions[9] = new Array(9, "AO", "Angola", 0, 0, 0, 0, false, false, 0, "");
			regions[10] = new Array(10, "AI", "Anguilla", 0, 0, 0, 0, false, false, 0, "");
			regions[11] = new Array(11, "AQ", "Antarctica", 0, 0, 0, 0, false, false, 0, "");
			regions[12] = new Array(12, "AG", "Antigua and Barbuda", 0, 0, 0, 0, false, false, 0, "");
			regions[13] = new Array(13, "AR", "Argentina", 0, 0, 0, 0, false, false, 0, "");
			regions[14] = new Array(14, "AM", "Armenia", 0, 0, 0, 0, false, false, 0, "");
			regions[15] = new Array(15, "AW", "Aruba", 0, 0, 0, 0, false, false, 0, "");
			regions[16] = new Array(16, "AU", "Australia", 0, 0, 0, 0, false, false, 0, "");
			regions[17] = new Array(17, "AZ", "Azerbaijan", 0, 0, 0, 0, false, false, 0, "");
			regions[18] = new Array(18, "BS", "Bahamas", 0, 0, 0, 0, false, false, 0, "");
			regions[19] = new Array(19, "BH", "Bahrain", 0, 0, 0, 0, false, false, 0, "");
			regions[20] = new Array(20, "BD", "Bangladesh", 0, 0, 0, 0, false, false, 0, "");
			regions[21] = new Array(21, "BB", "Barbados", 0, 0, 0, 0, false, false, 0, "");
			regions[22] = new Array(22, "BY", "Belarus", 0, 0, 0, 0, false, false, 0, "");
			regions[23] = new Array(23, "BE", "Belgium", 7, 7, 0, 0, false, false, 1, "^BE[ ]{0,1}[0-9]{9}$");
			regions[24] = new Array(24, "BZ", "Belize", 0, 0, 0, 0, false, false, 0, "");
			regions[25] = new Array(25, "BJ", "Benin", 0, 0, 0, 0, false, false, 0, "");
			regions[26] = new Array(26, "BM", "Bermuda", 0, 0, 0, 0, false, false, 0, "");
			regions[27] = new Array(27, "BT", "Bhutan", 0, 0, 0, 0, false, false, 0, "");
			regions[28] = new Array(28, "BO", "Bolivia", 0, 0, 0, 0, false, false, 0, "");
			regions[29] = new Array(29, "BA", "Bosnia and Herzegovina", 0, 0, 0, 0, false, false, 0, "");
			regions[30] = new Array(30, "BW", "Botswana", 0, 0, 0, 0, false, false, 0, "");
			regions[31] = new Array(31, "BV", "Bouvet Island", 0, 0, 0, 0, false, false, 0, "");
			regions[32] = new Array(32, "BR", "Brazil", 0, 0, 0, 0, false, false, 0, "");
			regions[33] = new Array(33, "IO", "British Indian Ocean Territory", 0, 0, 0, 0, false, false, 0, "");
			regions[34] = new Array(34, "BN", "Brunei Darussalam", 0, 0, 0, 0, false, false, 0, "");
			regions[35] = new Array(35, "BG", "Bulgaria", 7, 0, 0, 0, false, false, 1, "^BG[ ]{0,1}([0-9]{9}|[0-9]{10})$");
			regions[36] = new Array(36, "BF", "Burkina Faso", 0, 0, 0, 0, false, false, 0, "");
			regions[37] = new Array(37, "BI", "Burundi", 0, 0, 0, 0, false, false, 0, "");
			regions[38] = new Array(38, "KH", "Cambodia", 0, 0, 0, 0, false, false, 0, "");
			regions[39] = new Array(39, "CM", "Cameroon", 0, 0, 0, 0, false, false, 0, "");
			regions[40] = new Array(40, "CA", "Canada", 0, 0, 0, 0, false, false, 0, "");
			regions[41] = new Array(41, "CV", "Cape Verde", 0, 0, 0, 0, false, false, 0, "");
			regions[42] = new Array(42, "KY", "Cayman Islands", 0, 0, 0, 0, false, false, 0, "");
			regions[43] = new Array(43, "CF", "Central African Republic", 0, 0, 0, 0, false, false, 0, "");
			regions[44] = new Array(44, "TD", "Chad", 0, 0, 0, 0, false, false, 0, "");
			regions[45] = new Array(45, "CL", "Chile", 0, 0, 0, 0, false, false, 0, "");
			regions[46] = new Array(46, "CN", "China", 0, 0, 0, 0, false, false, 0, "");
			regions[47] = new Array(47, "CX", "Christmas Island", 0, 0, 0, 0, false, false, 0, "");
			regions[48] = new Array(48, "CC", "Cocos (Keeling) Islands", 0, 0, 0, 0, false, false, 0, "");
			regions[49] = new Array(49, "CO", "Colombia", 0, 0, 0, 0, false, false, 0, "");
			regions[50] = new Array(50, "KM", "Comoros", 0, 0, 0, 0, false, false, 0, "");
			regions[51] = new Array(51, "CG", "Congo (Brazzaville)", 0, 0, 0, 0, false, false, 0, "");
			regions[52] = new Array(52, "CD", "Congo (Kinshasa)", 0, 0, 0, 0, false, false, 0, "");
			regions[53] = new Array(53, "CK", "Cook Islands", 0, 0, 0, 0, false, false, 0, "");
			regions[54] = new Array(54, "CR", "Costa Rica", 0, 0, 0, 0, false, false, 0, "");
			regions[55] = new Array(55, "CI", "Côte d'Ivoire", 0, 0, 0, 0, false, false, 0, "");
			regions[56] = new Array(56, "HR", "Croatia", 0, 0, 0, 0, false, false, 0, "");
			regions[57] = new Array(57, "CU", "Cuba", 0, 0, 0, 0, false, false, 0, "");
			regions[58] = new Array(58, "CY", "Cyprus", 7, 0, 0, 0, false, false, 2, "^CY[ ]{0,1}[0-9]{9}$");
			regions[59] = new Array(59, "CZ", "Czech Republic", 0, 0, 0, 0, false, false, 1, "^CZ[ ]{0,1}([0-9]{8}|[0-9]{9})|[0-9]{10})$");
			regions[60] = new Array(60, "DK", "Denmark", 0, 0, 0, 0, false, false, 1, "^DK[ ]{0,1}[0-9]{8}$");
			regions[61] = new Array(61, "DJ", "Djibouti", 0, 0, 0, 0, false, false, 0, "");
			regions[62] = new Array(62, "DM", "Dominica", 0, 0, 0, 0, false, false, 0, "");
			regions[63] = new Array(63, "DO", "Dominican Republic", 0, 0, 0, 0, false, false, 0, "");
			regions[64] = new Array(64, "EC", "Ecuador", 0, 0, 0, 0, false, false, 0, "");
			regions[65] = new Array(65, "EG", "Egypt", 0, 0, 0, 0, false, false, 0, "");
			regions[66] = new Array(66, "SV", "El Salvador", 0, 0, 0, 0, false, false, 0, "");
			regions[67] = new Array(67, "GQ", "Equatorial Guinea", 0, 0, 0, 0, false, false, 0, "");
			regions[68] = new Array(68, "ER", "Eritrea", 0, 0, 0, 0, false, false, 0, "");
			regions[69] = new Array(69, "EE", "Estonia", 0, 0, 0, 0, false, false, 1, "^EE[ ]{0,1}[0-9]{9}$");
			regions[70] = new Array(70, "ET", "Ethiopia", 0, 0, 0, 0, false, false, 0, "");
			regions[71] = new Array(71, "FK", "Falkland Islands", 0, 0, 0, 0, false, false, 0, "");
			regions[72] = new Array(72, "FO", "Faroe Islands", 0, 0, 0, 0, false, false, 0, "");
			regions[73] = new Array(73, "FJ", "Fiji", 0, 0, 0, 0, false, false, 0, "");
			regions[74] = new Array(74, "FI", "Finland", 0, 0, 0, 0, false, false, 1, "^FI[ ]{0,1}[0-9]{8}$");
			regions[75] = new Array(75, "FR", "France", 0, 0, 0, 0, false, false, 1, "^FR[ ]{0,1}[a-zA-Z0-9]{2}[0-9]{9}$");
			regions[76] = new Array(76, "GF", "French Guiana", 0, 0, 0, 0, false, false, 0, "");
			regions[77] = new Array(77, "PF", "French Polynesia", 0, 0, 0, 0, false, false, 0, "");
			regions[78] = new Array(78, "TF", "French Southern Lands", 0, 0, 0, 0, false, false, 0, "");
			regions[79] = new Array(79, "GA", "Gabon", 0, 0, 0, 0, false, false, 0, "");
			regions[80] = new Array(80, "GM", "Gambia", 0, 0, 0, 0, false, false, 0, "");
			regions[81] = new Array(81, "GE", "Georgia", 0, 0, 0, 0, false, false, 0, "");
			regions[82] = new Array(82, "GH", "Ghana", 0, 0, 0, 0, false, false, 0, "");
			regions[83] = new Array(83, "GI", "Gibraltar", 0, 0, 0, 0, false, false, 0, "");
			regions[84] = new Array(84, "EL", "Greece", 0, 0, 0, 0, false, false, 1, "^EL[ ]{0,1}[0-9]{9}$");
			regions[85] = new Array(85, "GL", "Greenland", 0, 0, 0, 0, false, false, 0, "");
			regions[86] = new Array(86, "GD", "Grenada", 0, 0, 0, 0, false, false, 0, "");
			regions[87] = new Array(87, "GP", "Guadeloupe", 0, 0, 0, 0, false, false, 0, "");
			regions[88] = new Array(88, "GU", "Guam", 0, 0, 0, 0, false, false, 0, "");
			regions[89] = new Array(89, "GT", "Guatemala", 0, 0, 0, 0, false, false, 0, "");
			regions[90] = new Array(90, "GN", "Guinea", 0, 0, 0, 0, false, false, 0, "");
			regions[91] = new Array(91, "GW", "Guinea-Bissau", 0, 0, 0, 0, false, false, 0, "");
			regions[92] = new Array(92, "GY", "Guyana", 0, 0, 0, 0, false, false, 0, "");
			regions[93] = new Array(93, "HT", "Haiti", 0, 0, 0, 0, false, false, 0, "");
			regions[94] = new Array(94, "HM", "Heard and McDonald Islands", 0, 0, 0, 0, false, false, 0, "");
			regions[95] = new Array(95, "HN", "Honduras", 0, 0, 0, 0, false, false, 0, "");
			regions[96] = new Array(96, "HK", "Hong Kong", 0, 0, 0, 0, false, false, 0, "");
			regions[97] = new Array(97, "HU", "Hungary", 0, 0, 0, 0, false, false, 1, "^HU[ ]{0,1}[0-9]{8}$");
			regions[98] = new Array(98, "IS", "Iceland", 0, 0, 0, 0, false, false, 0, "");
			regions[99] = new Array(99, "IN", "India", 0, 0, 0, 0, false, false, 0, "");
			regions[100] = new Array(100, "ID", "Indonesia", 0, 0, 0, 0, false, false, 0, "");
			regions[101] = new Array(101, "IR", "Iran", 0, 0, 0, 0, false, false, 0, "");
			regions[102] = new Array(102, "IQ", "Iraq", 0, 0, 0, 0, false, false, 0, "");
			regions[103] = new Array(103, "IE", "Ireland", 0, 0, 0, 0, false, false, 1, "^IE[ ]{0,1}[0-9][0-9a-zA-Z][0-9]{5}[a-zA-Z]$");
			regions[104] = new Array(104, "IL", "Israel", 0, 0, 0, 0, false, false, 0, "");
			regions[105] = new Array(105, "IT", "Italy", 0, 0, 0, 0, false, false, 1, "^IT[ ]{0,1}[0-9]{11}$");
			regions[106] = new Array(106, "JM", "Jamaica", 0, 0, 0, 0, false, false, 0, "");
			regions[107] = new Array(107, "JP", "Japan", 0, 0, 0, 0, false, false, 0, "");
			regions[108] = new Array(108, "JO", "Jordan", 0, 0, 0, 0, false, false, 0, "");
			regions[109] = new Array(109, "KZ", "Kazakhstan", 0, 0, 0, 0, false, false, 0, "");
			regions[110] = new Array(110, "KE", "Kenya", 0, 0, 0, 0, false, false, 0, "");
			regions[111] = new Array(111, "KI", "Kiribati", 0, 0, 0, 0, false, false, 0, "");
			regions[112] = new Array(112, "KP", "Korea North", 0, 0, 0, 0, false, false, 0, "");
			regions[113] = new Array(113, "KR", "Korea South", 0, 0, 0, 0, false, false, 0, "");
			regions[114] = new Array(114, "KW", "Kuwait", 0, 0, 0, 0, false, false, 0, "");
			regions[115] = new Array(115, "KG", "Kyrgyzstan", 0, 0, 0, 0, false, false, 0, "");
			regions[116] = new Array(116, "LA", "Laos", 0, 0, 0, 0, false, false, 0, "");
			regions[117] = new Array(117, "LV", "Latvia", 7, 0, 5, 9, false, false, 2, "^LV[ ]{0,1}[0-9]{11}$");
			regions[118] = new Array(118, "LB", "Lebanon", 0, 0, 0, 0, false, false, 0, "");
			regions[119] = new Array(119, "LS", "Lesotho", 0, 0, 0, 0, false, false, 0, "");
			regions[120] = new Array(120, "LR", "Liberia", 0, 0, 0, 0, false, false, 0, "");
			regions[121] = new Array(121, "LY", "Libya", 0, 0, 0, 0, false, false, 0, "");
			regions[122] = new Array(122, "LI", "Liechtenstein", 0, 0, 0, 0, false, false, 0, "");
			regions[123] = new Array(123, "LT", "Lithuania", 0, 0, 0, 0, false, false, 1, "^LT[ ]{0,1}([0-9]{9}|[0-9]{12})$");
			regions[124] = new Array(124, "LU", "Luxembourg", 0, 0, 0, 0, false, false, 1, "^LU[ ]{0,1}[0-9]{8}$");
			regions[125] = new Array(125, "MO", "Macau", 0, 0, 0, 0, false, false, 0, "");
			regions[126] = new Array(126, "MK", "Macedonia", 0, 0, 0, 0, false, false, 0, "");
			regions[127] = new Array(127, "MG", "Madagascar", 0, 0, 0, 0, false, false, 0, "");
			regions[128] = new Array(128, "MW", "Malawi", 0, 0, 0, 0, false, false, 0, "");
			regions[129] = new Array(129, "MY", "Malaysia", 0, 0, 0, 0, false, false, 0, "");
			regions[130] = new Array(130, "MV", "Maldives", 0, 0, 0, 0, false, false, 0, "");
			regions[131] = new Array(131, "ML", "Mali", 0, 0, 0, 0, false, false, 0, "");
			regions[132] = new Array(132, "MT", "Malta", 0, 0, 0, 0, false, false, 1, "^MT[ ]{0,1}[0-9]{8}$");
			regions[133] = new Array(133, "MH", "Marshall Islands", 0, 0, 0, 0, false, false, 0, "");
			regions[134] = new Array(134, "MQ", "Martinique", 0, 0, 0, 0, false, false, 0, "");
			regions[135] = new Array(135, "MR", "Mauritania", 0, 0, 0, 0, false, false, 0, "");
			regions[136] = new Array(136, "MU", "Mauritius", 0, 0, 0, 0, false, false, 0, "");
			regions[137] = new Array(137, "YT", "Mayotte", 0, 0, 0, 0, false, false, 0, "");
			regions[138] = new Array(138, "MX", "Mexico", 0, 0, 0, 0, false, false, 0, "");
			regions[139] = new Array(139, "FM", "Micronesia", 0, 0, 0, 0, false, false, 0, "");
			regions[140] = new Array(140, "MD", "Moldova", 0, 0, 0, 0, false, false, 0, "");
			regions[141] = new Array(141, "MC", "Monaco", 0, 0, 0, 0, false, false, 0, "");
			regions[142] = new Array(142, "MN", "Mongolia", 0, 0, 0, 0, false, false, 0, "");
			regions[143] = new Array(143, "MS", "Montserrat", 0, 0, 0, 0, false, false, 0, "");
			regions[144] = new Array(144, "MA", "Morocco", 0, 0, 0, 0, false, false, 0, "");
			regions[145] = new Array(145, "MZ", "Mozambique", 0, 0, 0, 0, false, false, 0, "");
			regions[146] = new Array(146, "MM", "Myanmar", 0, 0, 0, 0, false, false, 0, "");
			regions[147] = new Array(147, "NA", "Namibia", 0, 0, 0, 0, false, false, 0, "");
			regions[148] = new Array(148, "NR", "Nauru", 0, 0, 0, 0, false, false, 0, "");
			regions[149] = new Array(149, "NP", "Nepal", 0, 0, 0, 0, false, false, 0, "");
			regions[150] = new Array(150, "NL", "Netherlands", 0, 0, 0, 0, false, false, 1, "^NL[ ]{0,1}[0-9]{9}B[0-9]{2}$");
			regions[151] = new Array(151, "AN", "Netherlands Antilles", 0, 0, 0, 0, false, false, 0, "");
			regions[152] = new Array(152, "NC", "New Caledonia", 0, 0, 0, 0, false, false, 0, "");
			regions[153] = new Array(153, "NZ", "New Zealand", 0, 0, 0, 0, false, false, 0, "");
			regions[154] = new Array(154, "NI", "Nicaragua", 0, 0, 0, 0, false, false, 0, "");
			regions[155] = new Array(155, "NE", "Niger", 0, 0, 0, 0, false, false, 0, "");
			regions[156] = new Array(156, "NG", "Nigeria", 0, 0, 0, 0, false, false, 0, "");
			regions[157] = new Array(157, "NU", "Niue", 0, 0, 0, 0, false, false, 0, "");
			regions[158] = new Array(158, "NF", "Norfolk Island", 0, 0, 0, 0, false, false, 0, "");
			regions[159] = new Array(159, "MP", "Northern Mariana Islands", 0, 0, 0, 0, false, false, 0, "");
			regions[160] = new Array(160, "NO", "Norway", 0, 0, 0, 0, false, false, 2, "");
			regions[161] = new Array(161, "OM", "Oman", 0, 0, 0, 0, false, false, 0, "");
			regions[162] = new Array(162, "PK", "Pakistan", 0, 0, 0, 0, false, false, 0, "");
			regions[163] = new Array(163, "PW", "Palau", 0, 0, 0, 0, false, false, 0, "");
			regions[164] = new Array(164, "PS", "Palestine", 0, 0, 0, 0, false, false, 0, "");
			regions[165] = new Array(165, "PA", "Panama", 0, 0, 0, 0, false, false, 0, "");
			regions[166] = new Array(166, "PG", "Papua New Guinea", 0, 0, 0, 0, false, false, 0, "");
			regions[167] = new Array(167, "PY", "Paraguay", 0, 0, 0, 0, false, false, 0, "");
			regions[168] = new Array(168, "PE", "Peru", 0, 0, 0, 0, false, false, 0, "");
			regions[169] = new Array(169, "PH", "Philippines", 0, 0, 0, 0, false, false, 0, "");
			regions[170] = new Array(170, "PN", "Pitcairn", 0, 0, 0, 0, false, false, 0, "");
			regions[171] = new Array(171, "PL", "Poland", 0, 0, 0, 0, false, false, 1, "^PL[ ]{0,1}[0-9]{10}$");
			regions[172] = new Array(172, "PT", "Portugal", 0, 0, 0, 0, false, false, 1, "^PT[ ]{0,1}[0-9]{9}$");
			regions[173] = new Array(173, "PR", "Puerto Rico", 0, 0, 0, 0, false, false, 0, "");
			regions[174] = new Array(174, "QA", "Qatar", 0, 0, 0, 0, false, false, 0, "");
			regions[175] = new Array(175, "RE", "Reunion", 0, 0, 0, 0, false, false, 0, "");
			regions[176] = new Array(176, "RO", "Romania", 7, 0, 0, 0, false, false, 2, "^RO[ ]{0,1}[0-9]{10}$");
			regions[177] = new Array(177, "RU", "Russian Federation", 0, 0, 0, 0, false, false, 0, "");
			regions[178] = new Array(178, "RW", "Rwanda", 0, 0, 0, 0, false, false, 0, "");
			regions[179] = new Array(179, "SH", "Saint Helena", 0, 0, 0, 0, false, false, 0, "");
			regions[180] = new Array(180, "KN", "Saint Kitts and Nevis", 0, 0, 0, 0, false, false, 0, "");
			regions[181] = new Array(181, "LC", "Saint Lucia", 0, 0, 0, 0, false, false, 0, "");
			regions[182] = new Array(182, "PM", "Saint Pierre and Miquelon", 0, 0, 0, 0, false, false, 0, "");
			regions[183] = new Array(183, "VC", "Saint Vincent and the Grenadines", 0, 0, 0, 0, false, false, 0, "");
			regions[184] = new Array(184, "WS", "Samoa", 0, 0, 0, 0, false, false, 0, "");
			regions[185] = new Array(185, "SM", "San Marino", 0, 0, 0, 0, false, false, 0, "");
			regions[186] = new Array(186, "ST", "Sao Tome and Principe", 0, 0, 0, 0, false, false, 0, "");
			regions[187] = new Array(187, "SA", "Saudi Arabia", 0, 0, 0, 0, false, false, 0, "");
			regions[188] = new Array(188, "SN", "Senegal", 0, 0, 0, 0, false, false, 0, "");
			regions[189] = new Array(189, "CS", "Serbia and Montenegro", 0, 0, 0, 0, false, false, 0, "");
			regions[190] = new Array(190, "SC", "Seychelles", 0, 0, 0, 0, false, false, 0, "");
			regions[191] = new Array(191, "SL", "Sierra Leone", 0, 0, 0, 0, false, false, 0, "");
			regions[192] = new Array(192, "SG", "Singapore", 0, 0, 0, 0, false, false, 0, "");
			regions[193] = new Array(193, "SK", "Slovakia", 0, 0, 0, 0, false, false, 1, "^SK[ ]{0,1}[0-9]{10}$");
			regions[194] = new Array(194, "SI", "Slovenia", 0, 0, 0, 0, false, false, 1, "^SI[ ]{0,1}[0-9]{8}$");
			regions[195] = new Array(195, "SB", "Solomon Islands", 0, 0, 0, 0, false, false, 0, "");
			regions[196] = new Array(196, "SO", "Somalia", 0, 0, 0, 0, false, false, 0, "");
			regions[197] = new Array(197, "ZA", "South Africa", 0, 0, 0, 0, false, false, 0, "");
			regions[198] = new Array(198, "GS", "South Georgia and South Sandwich Islands", 0, 0, 0, 0, false, false, 0, "");
			regions[199] = new Array(199, "ES", "Spain", 7, 0, 0, 0, false, false, 2, "^ES[ ]{0,1}[a-zA-Z0-9][0-9]{7}[a-zA-Z0-9]$");
			regions[200] = new Array(200, "LK", "Sri Lanka", 0, 0, 0, 0, false, false, 0, "");
			regions[201] = new Array(201, "SD", "Sudan", 0, 0, 0, 0, false, false, 0, "");
			regions[202] = new Array(202, "SR", "Suriname", 0, 0, 0, 0, false, false, 0, "");
			regions[203] = new Array(203, "SJ", "Svalbard and Jan Mayen Islands", 0, 0, 0, 0, false, false, 0, "");
			regions[204] = new Array(204, "SZ", "Swaziland", 0, 0, 0, 0, false, false, 0, "");
			regions[205] = new Array(205, "SE", "Sweden", 0, 0, 0, 0, false, false, 1, "^SE[ ]{0,1}[0-9]{10}01$");
			regions[206] = new Array(206, "SY", "Syria", 0, 0, 0, 0, false, false, 0, "");
			regions[207] = new Array(207, "TW", "Taiwan", 0, 0, 0, 0, false, false, 0, "");
			regions[208] = new Array(208, "TJ", "Tajikistan", 0, 0, 0, 0, false, false, 0, "");
			regions[209] = new Array(209, "TZ", "Tanzania", 0, 0, 0, 0, false, false, 0, "");
			regions[210] = new Array(210, "TH", "Thailand", 0, 0, 0, 0, false, false, 0, "");
			regions[211] = new Array(211, "TL", "Timor-Leste", 0, 0, 0, 0, false, false, 0, "");
			regions[212] = new Array(212, "TG", "Togo", 0, 0, 0, 0, false, false, 0, "");
			regions[213] = new Array(213, "TK", "Tokelau", 0, 0, 0, 0, false, false, 0, "");
			regions[214] = new Array(214, "TO", "Tonga", 0, 0, 0, 0, false, false, 0, "");
			regions[215] = new Array(215, "TT", "Trinidad and Tobago", 0, 0, 0, 0, false, false, 0, "");
			regions[216] = new Array(216, "TN", "Tunisia", 0, 0, 0, 0, false, false, 0, "");
			regions[217] = new Array(217, "TR", "Turkey", 0, 0, 0, 0, false, false, 1, "");
			regions[218] = new Array(218, "TM", "Turkmenistan", 0, 0, 0, 0, false, false, 0, "");
			regions[219] = new Array(219, "TC", "Turks and Caicos Islands", 0, 0, 0, 0, false, false, 0, "");
			regions[220] = new Array(220, "TV", "Tuvalu", 0, 0, 0, 0, false, false, 0, "");
			regions[221] = new Array(221, "UG", "Uganda", 0, 0, 0, 0, false, false, 0, "");
			regions[222] = new Array(222, "UA", "Ukraine", 0, 0, 0, 0, false, false, 0, "");
			regions[223] = new Array(223, "AE", "United Arab Emirates", 0, 0, 0, 0, false, false, 0, "");
			regions[224] = new Array(224, "GB", "United Kingdom", 0, 0, 0, 0, false, false, 1, "^GB[ ]{0,1}([0-9]{9}|[0-9]{12})$");
			regions[225] = new Array(225, "UM", "United States Minor Outlying Islands", 0, 0, 0, 0, false, false, 0, "");
			regions[226] = new Array(226, "US", "United States of America", 0, 0, 0, 0, false, false, 0, "");
			regions[227] = new Array(227, "UY", "Uruguay", 0, 0, 0, 0, false, false, 0, "");
			regions[228] = new Array(228, "UZ", "Uzbekistan", 0, 0, 0, 0, false, false, 0, "");
			regions[229] = new Array(229, "VU", "Vanuatu", 0, 0, 0, 0, false, false, 0, "");
			regions[230] = new Array(230, "VA", "Vatican City", 0, 0, 0, 0, false, false, 0, "");
			regions[231] = new Array(231, "VE", "Venezuela", 0, 0, 0, 0, false, false, 0, "");
			regions[232] = new Array(232, "VN", "Viet Nam", 0, 0, 0, 0, false, false, 0, "");
			regions[233] = new Array(233, "VG", "Virgin Islands British", 0, 0, 0, 0, false, false, 0, "");
			regions[234] = new Array(234, "VI", "Virgin Islands U.S.", 0, 0, 0, 0, false, false, 0, "");
			regions[235] = new Array(235, "WF", "Wallis and Futuna Islands", 0, 0, 0, 0, false, false, 0, "");
			regions[236] = new Array(236, "EH", "Western Sahara", 0, 0, 0, 0, false, false, 0, "");
			regions[237] = new Array(237, "YE", "Yemen", 0, 0, 0, 0, false, false, 0, "");
			regions[238] = new Array(238, "ZM", "Zambia", 0, 0, 0, 0, false, false, 0, "");
			regions[239] = new Array(239, "ZW", "Zimbabwe", 0, 0, 0, 0, false, false, 0, "");
			
			};
		// executed on first session init only
		if(SMFirstInit){
			var SMReferrer = SMSession.xml.documentElement.getAttribute("referrer");
			var SMQuery = SMSession.xml.documentElement.getAttribute("query");
			SMShop.setAttribute("id", SMSession.xml.documentElement.getAttribute("id"));
			SMShop.setAttribute("finit", "1");
			SMShop.setAttribute("session-marker", "knVONzyMwjrfXiQCU01kIXP2OjazPoDB5QdRR7DuxUkLyw==");
			SMShop.setAttribute("build", "5.5.6");
			SMShop.setAttribute("sarurl", SMOMAbsoluteRootURL);
			if(SMReferrer!="") SMShop.setAttribute("referrer", SX_uEsc(SMReferrer));
			if(SMQuery!="") SMShop.setAttribute("query", SX_uEsc(SMQuery));
			SMShop.setAttribute("sid", fnSMRandStr(10));
			
			SMShop.setAttribute("finit", "0");
			};

		
		var SMProviderAddresses = new SXMLDom();with(SMProviderAddresses){documentElement = createNode("SMEmailService");with(documentElement){setAttribute("selfSender", "0");setAttribute("dateFormat", "d.m.Y H:i:s");setAttribute("remoteInfos", "1");setAttribute("referrer", SX_uEsc(SMSession.xml.documentElement.getAttribute("referrer")));setAttribute("adjustServerDate", "0");setAttribute("attachXml", "0");setAttribute("attachSmo", "0");setAttribute("attachOpenTrans", "0");setAttribute("attachLexware", "0");setAttribute("saveOrder", "1");setAttribute("smoEnabled", "0");setAttribute("smoHtmlCopy", "0");with(appendChild(ownerDocument.createNode("SMEmail"))){setAttribute("scope", "order");setAttribute("sender-name", "cover-city");text = "info_SM|AT_cover-city.com";};with(appendChild(ownerDocument.createNode("SMEmail"))){setAttribute("scope", "contact");setAttribute("sender-name", "cover-city");text = "info_SM|AT_cover-city.com";};with(appendChild(ownerDocument.createNode("SMEmail"))){setAttribute("scope", "newsletter");setAttribute("sender-name", "cover-city");text = "info_SM|AT_cover-city.com";};};};
		var SMColors = new SXMLDom();with(SMColors){documentElement = createNode("SMColors");with(documentElement){with(appendChild(ownerDocument.createNode("SMColor"))){setAttribute("key", "main");setAttribute("value", "#71939F");};with(appendChild(ownerDocument.createNode("SMColor"))){setAttribute("key", "main.light");setAttribute("value", "#D7E0E3");};with(appendChild(ownerDocument.createNode("SMColor"))){setAttribute("key", "main.dark");setAttribute("value", "#39697A");};with(appendChild(ownerDocument.createNode("SMColor"))){setAttribute("key", "alt");setAttribute("value", "#BEA081");};with(appendChild(ownerDocument.createNode("SMColor"))){setAttribute("key", "alt.light");setAttribute("value", "#E1D3C6");};with(appendChild(ownerDocument.createNode("SMColor"))){setAttribute("key", "alt.dark");setAttribute("value", "#74573D");};with(appendChild(ownerDocument.createNode("SMColor"))){setAttribute("key", "background");setAttribute("value", "#FFFFFF");};with(appendChild(ownerDocument.createNode("SMColor"))){setAttribute("key", "foreground");setAttribute("value", "#4E4E4E");};with(appendChild(ownerDocument.createNode("SMColor"))){setAttribute("key", "hyperlink");setAttribute("value", "#367589");};};};
		var SMFonts = new SXMLDom();with(SMFonts){documentElement = createNode("SMFonts");with(documentElement){with(appendChild(ownerDocument.createNode("SMFont"))){setAttribute("key","small");text="font-family:Tahoma, Helvetica, sans-serif;font-size:10px;font-weight:normal;";};with(appendChild(ownerDocument.createNode("SMFont"))){setAttribute("key","medium");text="font-family:Tahoma, Helvetica, sans-serif;font-size:11px;font-weight:normal;";};with(appendChild(ownerDocument.createNode("SMFont"))){setAttribute("key","large");text="font-family:Arial, Helvetica, sans-serif;font-size:14px;font-weight:bold;";};with(appendChild(ownerDocument.createNode("SMFont"))){setAttribute("key","x-large");text="font-family:Tahoma, Helvetica, sans-serif;font-size:17px;font-weight:bold;";};with(appendChild(ownerDocument.createNode("SMFont"))){setAttribute("key","xx-large");text="font-family:Tahoma, Helvetica, sans-serif;font-size:21px;font-weight:bold;";};};};

		var SMCfgItems = "_3CSMCfgItems_3E_3CSMCfgItem_20key=_22provider_X5X2bank_X5X2account_X5X2bic_22_3EGENODEF1ALT_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2bank_X5X2account_X5X2iban_22_3EDE47830654080004515617_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2bank_X5X2account_X5X2number_22_3E4515617_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2bank_X5X2account_X5X2owner_22_3EElke_X520Roidl_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2bank_X5X2code_22_3E83065410_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2bank_X5X2name_22_3EDeutsche_X520Skatbank_X520eG_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2city_22_3EHerschbach_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2company_X5X2director_22_3E_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2company_X5X2director_X5X2label_22_3EInhaber_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2company_X5X2name_22_3EElke_X520Roidl_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2country_X5X2name_22_3EDeutschland_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2fax_X5X2business_22_3E_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2fax_X5X2hotline_22_3E_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2firstname_22_3EElke_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2lastname_22_3ERoidl_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2mail_X5X2contact_22_3E_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2mail_X5X2default_22_3Einfo_X5X6cover_X5X2city_X5X3com_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2mail_X5X2orders_22_3E_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2mail_X5X2support_22_3E_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2mail_X5X2webmaster_22_3E_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2phone_X5X2business_22_3E_X5X149_X5206_X52043_X52059_X52020_X52062_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2phone_X5X2hotline_22_3E_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2phone_X5X2mobile_22_3E_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2region_22_3ERheinland_X5X2Pfalz_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2salutation_22_3EFrau_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2shopname_22_3EElke_X520Roidl_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2street_X5X2name_22_3EAm_X520Haseberg_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2street_X5X2number_22_3E21_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2tax_X5X2number_22_3E30_X5X4140_X5X44223_X5X41_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2title_22_3E_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2trade_X5X2number_22_3E_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2url_22_3Ehttp:_X5X4_X5X4www_X5X3cover_X5X2city_X5X3com_X5X4_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2vat_X5X2id_22_3E_3C_X4SMCfgItem_3E_3CSMCfgItem_20key=_22provider_X5X2zip_X5X2code_22_3E56414_3C_X4SMCfgItem_3E_3C_X4SMCfgItems_3E";
		var SMBasketXML = null;

		with(SMShop){
			
			deliveryTimes[1] = new Array(1, "sofort%20lieferbar");
			deliveryTimes[2] = new Array(2, "2-5%20Werktage");
			deliveryTimes[3] = new Array(3, "muss%20f%FCr%20Sie%20bestellt%20werden");
			};

		// listen to window.onLoad & .onUnload events
		window.onload = function(){ SMShop.onLoad(); };
		window.onunload = function(){ SMShop.onUnload(); };

	function SMOMGetQtyControl(){
	var _args = SMOMGetQtyControl.arguments, oProduct = _args[0], raiseEvent = ((_args[1]!=null) ? _args[1] : false), index = ((_args[2]!=null) ? _args[2] : -1);
	if(oProduct==null){return("")};
	var sPkid = "PD" + null2str(oProduct.getAttribute(_SMAUniqueID)), iQtyType = null2int(oProduct.getAttribute(_SMAOQtyType)),
			iQtyMin = null2int(oProduct.getAttribute(_SMAMinAmount)), iQtyStep = null2int(oProduct.getAttribute(_SMAOQtyStep)),
			iQtyMax = null2int(oProduct.getAttribute(_SMAMaxAmount)), iQtyDef = null2int(oProduct.getAttribute(_SMAOQDefValue)),
			iOptCount = null2int(oProduct.getAttribute(_SMAOQDDOptCount)), sQtyUnit = "Stk", sField = "";

		if(oProduct.getAttribute(_SMAVariantID)!=null) sPkid += '-' + oProduct.getAttribute(_SMAVariantID);
		sPkid += "Amount";

		iQtyDef = oProduct.getAttribute(_SMAAmount);
		iQtyDef = iQtyDef>iQtyMin?iQtyDef:iQtyMin;

		sField += "<table class=\"basket-line-qty\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\"><tr><td nowrap>";
		switch(iQtyType){
			case 0:
				sField += "<input class=\"addbasket-qtyfield\" id=\"" + sPkid + "\" type=\"text\" size=\"2\" value=\"" + iQtyDef + "\" onchange=\"this.value=fnSMNum(this.value);";
				if(raiseEvent) sField += "SMShop.base.raiseEvent('onBasketGUIElemChanged', false, null, SMShop, this, " + index + ");";
				sField += "\"";
				if(raiseEvent) sField += " onkeydown=\"if(window.event.keyCode==13){ this.value=fnSMNum(this.value); SMShop.base.raiseEvent('onBasketGUIElemChanged', false, null, SMShop, this, " + index + "); };\"";
				sField += "\">";
				break;
			case 1:
				if(raiseEvent) sPkid += "IDX" + index;
				sField += "<input class=\"addbasket-qtyfield\" id=\"" + sPkid + "\" type=\"text\" size=\"2\" value=\"" + iQtyDef + "\" onfocus=\"this.blur()\"";
				if(raiseEvent){
					sField += " onchange=\"SMShop.base.raiseEvent('onBasketGUIElemChanged', false, null, SMShop, this, " + index + ");\"";
					sField += " onkeydown=\"if(window.event.keyCode==13){ this.value=fnSMNum(this.value); SMShop.base.raiseEvent('onBasketGUIElemChanged', false, null, SMShop, this, " + index + "); };\"";
					};
				sField += "></td><td nowrap>";
				sField += "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\">";
				sField += "<tr><td style=\"padding-bottom:1px;\"><img src=\"images/button_spinup.gif\" alt=\"Bestellmenge erhöhen\" width=\"15\" height=\"8\" border=\"0\" onclick=\"fnSMSpinButtonClick('" + sPkid + "',true," + iQtyMin + "," + iQtyMax + "," + iQtyStep + ", true, " + index + ");\"></td></tr>";
				sField += "<tr><td><img src=\"images/button_spindown.gif\" alt=\"Bestellmenge verringern\" width=\"15\" height=\"8\" border=\"0\" onclick=\"fnSMSpinButtonClick('" + sPkid + "',false," + iQtyMin + "," + iQtyMax + "," + iQtyStep + ", true, " + index + ");\"></td></tr>";
				sField += "</table>";
				break;
			case 2:
				sField += "<select id=\"" + sPkid + "\" class=\"addbasket-qtyfield\"";
				if(raiseEvent){
					sField += " onchange=\"SMShop.base.raiseEvent('onBasketGUIElemChanged', false, null, SMShop, this, " + index + ");\"";
					sField += " onkeydown=\"if(window.event.keyCode==13){ this.value=fnSMNum(this.value); SMShop.base.raiseEvent('onBasketGUIElemChanged', false, null, SMShop, this, " + index + "); };\"";
					};
				sField += ">";
				for(var i=iQtyStep; i<=parseInt(iOptCount*iQtyStep);i+=iQtyStep){
					sField += "<option value=\"" + i + "\"";
					if(i==iQtyDef) sField += " selected";
					sField += ">" + i;
				};
				sField += "</select>";
				break;
		};
		sField += "</td></tr></table>";
		return(sField);
		};

	//page:SM_RESERVED_DATA_ENTRY_SHIPMENT

	// cSMShop.getCheckoutStep ( current-page-id, [previous?] )
	function SMGetCheckoutStep(){
	var backwards = arguments[1], returnId = "", usingShipToAddress = bNoCheckoutPage = false;
		usingShipToAddress = (SMShop.getFormElement("BILLTO", "BILLTO_SHIPTO_DIFFERS") != null);
		if(usingShipToAddress){
			usingShipToAddress = cbool(SMShop.getFormValue("BILLTO", "BILLTO_SHIPTO_DIFFERS", true));
			};
		switch(arguments[0]){
			case "SM_RESERVED_BASKET":
				returnId = (backwards) ? "warenkorb.htm" : "rechnungsadresse.htm";
				if(backwards) bNoCheckoutPage = true;
				break;
			case "SM_RESERVED_DATA_ENTRY_BILLTO":
				returnId = (backwards) ? "warenkorb.htm" : (usingShipToAddress) ? "lieferadresse.htm" : "versandart.htm";
				if(returnId == "warenkorb.htm") bNoCheckoutPage = true;
				break;
			case "SM_RESERVED_DATA_ENTRY_SHIPTO":
				returnId = (backwards) ? "rechnungsadresse.htm" : "versandart.htm";
				break;
			case "SM_RESERVED_DATA_ENTRY_SHIPMENT":
				returnId = (backwards) ? (usingShipToAddress) ? "lieferadresse.htm" : "rechnungsadresse.htm" : "zahlart.htm";
				break;
			case "SM_RESERVED_DATA_ENTRY_PAYMENT":
				returnId = (backwards) ? "versandart.htm" : "pruefen-und-senden.htm";
				break;
			case "SM_RESERVED_DATA_ENTRY_VERIFY":
				returnId = (backwards) ? "zahlart.htm" : "pruefen-und-senden.htm";
				if(returnId == "index.htm") bNoCheckoutPage = true;
				break;
			default:
				returnId = (backwards) ? "" : "index.htm";
				if(!backwards) bNoCheckoutPage = true;
			};
		// valid for checkout?
		if(returnId!=""){
			var sMsgValidity = "", lValidationCode = SMShop.validateDataForCheckout();
			switch(lValidationCode){
				case 1:
					sMsgValidity = "Your shopping cart contains no articles, please add at least one article to your shopping cart. Ihr Warenkorb enthält keine Einträge, bitte legen Sie mindestens einen Artikel in den Warenkorb. ".replace("&nbsp;", " ");
					alert(sMsgValidity);
					returnId = "index.htm";
					bNoCheckoutPage = true;
					break;
				case 2:
					sMsgValidity = ("Der Mindestbestellwert wurde unterschritten.  " + cprimary.format(SMShop.getAttribute(_SMAMinAmount), SM_CSYMBOL + SM_CGROUP)).replace("&nbsp;", " ");
					alert(sMsgValidity);
					returnId = "warenkorb.htm";
					bNoCheckoutPage = true;
					break;
				};
			}
		else return("");
		// ssl
		if(useSSLForCheckout&&SMOMAbsoluteRootURL.substring(0,7)=="http://"){
			if(sharedSSLURL!=""){
				SMOMAbsoluteRootURL = sharedSSLURL;
				}
			else SMOMAbsoluteRootURL = "https://" + SMOMAbsoluteRootURL.substring(7);
			};
		if(SMOMAbsoluteRootURL.substring(SMOMAbsoluteRootURL.length - 1)=="/") SMOMAbsoluteRootURL = SMOMAbsoluteRootURL.substring(0,SMOMAbsoluteRootURL.length - 1);
		
		if(bNoCheckoutPage && SMShop.getAttribute('sarurl') != ''){
			returnId = SMShop.getAttribute('sarurl') + "/" + returnId;
		} else {
			returnId = SMOMAbsoluteRootURL + "/" + returnId;
		};
		
		return(returnId);
		};

		SMCurrNoOfDecimals = 2;
	var cprimary = new cSMCurrency("EUR", "€", "Euro", ",", "1,1 x", "-1,1 x", 2, ".", 3, 1 );
	var csecondary = new cSMCurrency("USD", "$", "United States Dollars", ",", "1,1 x", "-1,1 x", 2, ".", 3, 1.2094639753 );

	var nprimary = new cSMCurrency("kg", "kg", "kg", ",", "1,1 x", "-1,1 x", 2, "", 3, 1);

	if(SMFirstInit){
		SMShop.basket.setAttribute("p-cur-iso", cprimary.ISO)
		SMShop.basket.setAttribute("p-cur-symbol", cprimary.symbol)
		};	

	function formatProductBasePrice(Product){
	var $basePriceTemplate = "";
		$basePriceTemplate = "Grundpreis: %bp pro %mb %mu";
		if($basePriceTemplate!=""&&(Product.bpAmount!=1||Product.bpBase!=1)){
			$basePriceTemplate = $basePriceTemplate.replace(/%ma/g, Product.bpAmount);
			$basePriceTemplate = $basePriceTemplate.replace(/%mu/g, Product.bpMUnit);
			$basePriceTemplate = $basePriceTemplate.replace(/%qu/g, Product.quantityUnit);
			$basePriceTemplate = $basePriceTemplate.replace(/%bp/g, "<strong class=\"t-em\">" + cprimary.format(Product.getPrice() / Product.bpAmount * Product.bpBase, SM_CGROUP + SM_CSYMBOL) + "</strong>");
			$basePriceTemplate = $basePriceTemplate.replace(/%mb/g, Product.bpBase);
			}
		else $basePriceTemplate = "";
		return($basePriceTemplate);
		};

	function displayProductProperties(Product){
	var $image = null, $elem = null, $basePriceTemplate = "", $fSetData = function(){ var $elem = null; try{ $elem = document.getElementById(arguments[0]); if($elem!=null) $elem.innerHTML = arguments[1]; } catch(e){ }; };
		/*
		$basePriceTemplate = "Grundpreis: %bp pro %mb %mu";
		if($basePriceTemplate!=""&&(Product.bpAmount!=1||Product.bpBase!=1)){
			$basePriceTemplate = $basePriceTemplate.replace(/%ma/g, Product.bpAmount);
			$basePriceTemplate = $basePriceTemplate.replace(/%mu/g, Product.bpMUnit);
			$basePriceTemplate = $basePriceTemplate.replace(/%qu/g, Product.quantityUnit);
			$basePriceTemplate = $basePriceTemplate.replace(/%bp/g, "<strong class=\"t-em\">" + cprimary.format(Product.getPrice() / Product.bpAmount * Product.bpBase, SM_CGROUP + SM_CSYMBOL) + "</strong>");
			$basePriceTemplate = $basePriceTemplate.replace(/%mb/g, Product.bpBase);
			}
		else $basePriceTemplate = "";
		*/
		try{
			$image = new Image();
			$image.src = Product.image;
			}
		catch(e){
			$image = null;
			};
		with(document){
			if($image!=null&&Product.image!=""){
				if(getElementById("product_picture")){
					getElementById("product_picture").src = $image.src;
					};
				};
			$fSetData("product_name", Product.name);
			$fSetData("product_desc", Product.desc);
			$fSetData("product_id", Product.getAttribute(_SMACode));
			$fSetData("product_weight", nprimary.format(Product.getAttribute(_SMAWeight), SM_CGROUP));
			$fSetData("product_original_price", cprimary.format(Product.getOriginalPrice(), SM_CGROUP + SM_CSYMBOL));
			$fSetData("product_price", cprimary.format(Product.getPrice(), SM_CGROUP + SM_CSYMBOL));
			$fSetData("product_price_seccur", csecondary.format(Product.getPrice(), SM_CGROUP + SM_CSYMBOL));
			$fSetData("product_discounts", Product.discounts.renderHTML());
			$fSetData("product_base_price", formatProductBasePrice(Product));
			/* $fSetData("product_base_price", $basePriceTemplate); */
			if(Product.deliveryTimeFKID!=0){
				$fSetData("product_delivery_caption", unescape(SMShop.deliveryTimes[Product.deliveryTimeFKID][1]));
				};
			$elem = getElementById("product_delivery_img");
			if($elem&&Product.deliveryTimeFKID!=0){
				try{
					$image = new Image();
					$image.src = $elem.src.replace(/(.+\/[^\d\/]+)\d+(\.[a-z]+)/gi, "$1" + Product.deliveryTimeFKID + "$2");
					}
				catch(e){ $image = null };
				if($image!=null) $elem.src = $image.src;
				};
			};
		};

	/* sm:broker-url begin-edit */
	var SMBrokerURL = "https://www.smartstore.com/services/smbiz_smartbroker.php5";
	/* sm:broker-url end-edit */
