var _ctgoNode=0,_hoverTimeout=100;function swapImageOver(){this.src=this.src.replace(/\.([a-z]+)$/i,".hover.$1")}function swapImageOut(){this.src=this.src.replace(/\.hover\.([a-z]+)$/i,".$1")}function hoverLink(a){if(!this.id){this.id="__contegnoDOM_"+_ctgoNode++}this.className+=" hover";setTimeout('$("#'+this.id+'").removeClass("hover")',_hoverTimeout)}function hoverImage(b){var a=this.src;this.src=this.src.replace(/\.([a-z]+)$/i,".hover.$1");if(!this.id){this.id="__contegnoDOM_"+_ctgoNode++}setTimeout('$("#'+this.id+'").attr("src", "'+a+'")',_hoverTimeout)}function initCarSpecialForm(){$("#car-special-brand, #car-special-model").change(function(){this.form.submit()});$("#car-special-submit").hide()}function openFlashBook(c,e){var a,g,b,d={allowFullScreen:"false",allowScriptAccess:"sameDomain",bgcolor:"#000000",devicefont:"false",height:"704",loop:"true",menu:"true",play:"true",quality:"high",scale:"showall",width:"1024",wmode:"transparent"},f=document.getElementsByTagName("HTML")[0];switch(c){case"butterfly":a="Buch%201";break;case"car-special":a="Buch%202";break;default:return true}g=document.createElement("DIV");g.id="flash-book-wrapper";g.style.width=(f.scrollWidth>1024?f.scrollWidth:1024)+"px";g.style.height=(f.scrollHeight>658?f.scrollHeight:658)+"px";document.body.appendChild(g);b=document.createElement("DIV");b.id="flash-book";document.body.appendChild(b);swfobject.embedSWF("/asset/flash/buch/"+a+".swf","flash-book",1024,658,"9.0.0",null,{verzeichnis:"/asset/flash/buch",sprache:e},d);document.body.scrollIntoView(true);return false}function closeFlashBook(){$("#flash-book, #flash-book-button, #flash-book-wrapper").remove()}function initGallerySlideShow(d){var c,b,a;for(c=0;node=$("#"+d.nodes[c])[0];++c){b=document.createElement("SPAN");b.className="separator";b.innerHTML=" | ";node.parentNode.insertBefore(b,node);a=document.createElement("SPAN");if(d.sku){a.onclick=new Function("openGallerySlideShow('/slideshow/SKU"+d.sku+".xml', '"+d.search_uri+"', '"+d.sessid+"')")}else{if(d.property){a.onclick=new Function("openGallerySlideShow('/slideshow/prop-"+d.property+".xml', '"+d.search_uri+"', '"+d.sessid+"')")}else{if(d.search_type){a.onclick=new Function("openGallerySlideShow('/slideshow/search-type-"+d.search_type+".xml', '"+d.search_uri+"', '"+d.sessid+"')")}}}a.className="slide-show-link";a.innerHTML=d.label;node.parentNode.replaceChild(a,node)}}function openGallerySlideShow(b,c,d){var g,a,e={allowFullScreen:"false",allowScriptAccess:"sameDomain",bgcolor:"#000000",devicefont:"false",height:"704",loop:"true",menu:"true",play:"true",quality:"high",scale:"showall",width:"1024",wmode:"transparent"},f=document.getElementsByTagName("HTML")[0];g=document.createElement("DIV");g.id="slide-show-wrapper";g.style.width=(f.scrollWidth>1024?f.scrollWidth:1024)+"px";g.style.height=(f.scrollHeight>704?f.scrollHeight:704)+"px";document.body.appendChild(g);a=document.createElement("DIV");a.id="slide-show";document.body.appendChild(a);swfobject.embedSWF("/asset/flash/slideshow.swf","slide-show",1024,704,"9.0.0",false,{verzeichnis:b,suche:c,session:d},e);document.body.scrollIntoView(true);return false}function closeGallerySlideShow(){$("#slide-show, #slide-show-button, #slide-show-wrapper").remove()}function initLabeledInput(c,a){if($("#"+c).val()==""){$("#"+c).val(a)}$("#"+c).attr("label",a).focus(function(){if(this.value==a){this.value=""}}).blur(function(){if(this.value==""){this.value=a}});var b=$("#"+c)[0];if(b==null||b.form==null){return}$(b.form).submit(function(d){if(b.value==$(b).attr("label")){if(d&&d.preventDefault){d.preventDefault()}return false}})}function initFontWeightForm(){$("#font-weights input.doShoppingCartAddItem").each(function(){if(!(m=this.name.match(/^do\[ShoppingCartAddItem\]\[~(\d+)~\]$/))){return}this.productItemId=m[1];$(this).click(function(a){id=window.event?window.event.srcElement.productItemId:a.target.productItemId;if($("#productItemId_"+id).val()==""){if(!$("#productItemIdLabel_"+id).hasClass("error")){$("#productItemIdLabel_"+id).addClass("error")}if(a&&a.preventDefault){a.preventDefault()}return false}})})}function initSlideshow(b,a){$.get("/wservice/slideshow.php",{context:a},function(c){$("#"+b).Slides({images:c,pause:5000,fade:2000})},"json")}function htmlSpecialChars(a){return a.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;")}sprintfWrapper={init:function(){if(typeof arguments=="undefined"){return null}if(arguments.length<1){return null}if(typeof arguments[0]!="string"){return null}if(typeof RegExp=="undefined"){return null}var j=arguments[0],c=new RegExp(/(%([%]|(\-)?(\+|\x20)?(0)?(\d+)?(\.(\d)?)?([bcdfosxX])))/g),g=new Array(),l=new Array(),a=0,h=0,n=0,d=0,k="",b=null,f=null,e=null;while(f=c.exec(j)){if(f[9]){a+=1}h=d;n=c.lastIndex-f[0].length;l[l.length]=j.substring(h,n);d=c.lastIndex;g[g.length]={match:f[0],left:f[3]?true:false,sign:f[4]||"",pad:f[5]||" ",min:f[6]||0,precision:f[8],code:f[9]||"%",negative:parseInt(arguments[a])<0?true:false,argument:String(arguments[a])}}l[l.length]=j.substring(d);if(g.length==0){return j}if((arguments.length-1)<a){return null}b=f=e=null;for(e=0;e<g.length;++e){switch(g[e].code){case"%":substitution="%";break;case"b":g[e].argument=String(Math.abs(parseInt(g[e].argument)).toString(2));substitution=sprintfWrapper.convert(g[e],true);break;case"c":g[e].argument=String(String.fromCharCode(parseInt(Math.abs(parseInt(g[e].argument)))));substitution=sprintfWrapper.convert(g[e],true);break;case"d":g[e].argument=String(Math.abs(parseInt(g[e].argument)));substitution=sprintfWrapper.convert(g[e]);break;case"f":g[e].argument=String(Math.abs(parseFloat(g[e].argument)).toFixed(g[e].precision?g[e].precision:6));substitution=sprintfWrapper.convert(g[e]);break;case"o":g[e].argument=String(Math.abs(parseInt(g[e].argument)).toString(8));substitution=sprintfWrapper.convert(g[e]);break;case"s":g[e].argument=g[e].argument.substring(0,g[e].precision?g[e].precision:g[e].argument.length);substitution=sprintfWrapper.convert(g[e],true);break;case"x":g[e].argument=String(Math.abs(parseInt(g[e].argument)).toString(16));substitution=sprintfWrapper.convert(g[e]);break;case"X":g[e].argument=String(Math.abs(parseInt(g[e].argument)).toString(16));substitution=sprintfWrapper.convert(g[e]).toUpperCase();break;default:substitution=g[e].match}k+=l[e];k+=substitution}k+=l[e];return k},convert:function(b,d){var a,c;if(d){b.sign=""}else{b.sign=b.negative?"-":b.sign}a=b.min-b.argument.length+1-b.sign.length;c=new Array(a<0?0:a).join(b.pad);if(!b.left){if(b.pad=="0"||d){return b.sign+c+b.argument}else{return c+b.sign+b.argument}}else{if(b.pad=="0"||d){return b.sign+b.argument+c.replace(/0/g," ")}else{return b.sign+b.argument+c}}}};sprintf=sprintfWrapper.init;