dojo.require("dijit.layout.BorderContainer");dojo.require("dijit.layout.ContentPane");dojo.require("dojox.fx._base");dojo.require("dojox.timing._base");var imgButtonAlleFotos=new Image();var imgButtonAlleFotosGrey=new Image();imgButtonAlleFotos.src="menu/button_alle_fotos.gif";imgButtonAlleFotosGrey.src="menu/button_alle_fotos_grey.gif";var blackImg=new Image();var downloadImg=new Image();blackImg.src="blackimg.gif";downloadImg.src="image/downloadImg.gif";var werbungAnzahl=5;var werbungCurrent=0;var werbungImg=new Array();var werbungLink=new Array();werbungImg[0]=new Image();werbungImg[0].src="werbung/SuFresh-Logo__1.gif";werbungLink[0]="romena.ch";werbungImg[1]=new Image();werbungImg[1].src="werbung/brasilien_li_80.jpg";werbungLink[1]="brasilien.li";werbungImg[2]=new Image();werbungImg[2].src="werbung/logo_perfil.jpg";werbungLink[2]="jornal-perfil.ch";werbungImg[3]=new Image();werbungImg[3].src="werbung/bombalinks.png";werbungLink[3]="www.bombalinks.com";var rightContentPane;var leftDivContainer;var mainDivContainer;var leftMenuContentPane;var happyhourContentPane;var fotosBorderContainer;var fotosSmallContentPane;var fotosBigContentPane;var gesamtBreite=1025;var gesamtBreiteLinks=322;var gesamtBreiteRechts=gesamtBreite-gesamtBreiteLinks;var gesamtHoehe=610;var actualFotosTable=0;var actualFotoRow=0;var actualImg=0;var actualImgNo=-1;var fotoBig;var fotoBigLeft;var fotoBigRight;var sImage=new Array();var imageFile=new Array();var imageFileWidth=new Array();var img=new Array();var imgt=new Array();var tdimg=new Array();var tdimgt=new Array();var fotoRowTable=new Array();var showGalleryOnLoadOld;var getImageFileDone=false;var galleryLoadDone=false;var eventPath;var fotosScrollAnimation=null;var isFotosSmallDIVMinimized=false;var dxFotosRow=660;var isMenuMinimized=new Array(true,true,true,true,true);var menuHeight=new Array(20,0,0,20,0);var isgugus=false;var isgbsmiliesDivMinimized=true;var flyerInfoAnimation=null;var gbRange=null;dojo.addOnLoad(function(){mainDivContainer=new dijit.layout.BorderContainer({"design":"sidebar","gutters":false,"style":"height: "+gesamtHoehe+"px; width: "+gesamtBreite+"px; padding:0px; margin:0px;  border: 0px solid #333333;"},"mainDivContainer");leftDivContainer=new dijit.layout.BorderContainer({"design":"headline","gutters":false,"region":"left","style":"height: 100%; width:"+gesamtBreiteLinks+"px; border: 0px; padding:0px; margin:0px;"},"leftDivContainer");var _1=new dijit.layout.ContentPane({"region":"top","style":"width: 100%; height: 270px; background-color: black; border: 0px; padding: 0px; margin:0px;"},"leftImgContentPane");leftMenuContentPane=new dijit.layout.ContentPane({"region":"center","style":"width: 100%; height: "+(gesamtHoehe-270)+"px; text-align: left; background-color: black; border: 0px; padding: 40px 0px 0px 0px; margin:0px;overflow:hidden;"},"leftMenuContentPane");rightContentPane=new dijit.layout.ContentPane({"region":"center","style":"text-align:left; font-family:arial; width: 100%; height: 100%; background-color: black; color:white; padding: 0px; margin: 0px; border: 0px solid #333333; overflow:hidden;","loadingMessage":"Die Seite wird geladen! Bitte um etwas Geduld!!"},"rightContentPane");happyhourContentPane=new dijit.layout.ContentPane({"region":"center","style":"text-align:left; font-family:arial; width: 100%; height: 100%; background-color: black; color:white; padding: 0px; margin: 0px; border: 0px solid #333333; overflow:hidden;","loadingMessage":"Die Seite wird geladen! Bitte um etwas Geduld!!"},"happyhourContentPane");happyhourContentPane.attr("href","happyhour.html?g="+Math.random());_1.attr("content","<IMG SRC=\"coco_brasil_kopf.jpg\" width=\"320\" />");leftMenuContentPane.attr("href","menu.html?g="+Math.random());rightContentPane.attr("content","rechts..");leftDivContainer.addChild(_1);leftDivContainer.addChild(leftMenuContentPane);mainDivContainer.addChild(leftDivContainer);mainDivContainer.addChild(rightContentPane);setContentIMG("content/home.jpg");mainDivContainer.startup();werbungTimer=new dojox.timing.Timer();werbungTimer.setInterval(3000);werbungTimer.onTick=werbungTimerOnTick;werbungTimer.start();});function werbungTimerOnTick(){werbungCurrent=(werbungCurrent+1)%werbungAnzahl;var _2=dojo.byId("imgwerbung2");_2.src=werbungImg[werbungCurrent].src;if(werbungLink[werbungCurrent]==null){_2.style.cursor="default";}else{_2.style.cursor="pointer";}};function leftMenuContentPaneOnEnd(){var gg=dojo.byId("divwerbung");var g1=dojo.byId("imgwerbung1");alert("top: "+dojo._abs(gg).y);g1.style.top=dojo._abs(gg).y-50;g1.style.left=0;};function afterLoadingGallery(){if(!getImageFileDone||!galleryLoadDone){return;}initializeImg();rightContentPane.onLoad=showGalleryOnLoadOld;initializeSmallImages();};function checkFotosDIV(){var b=dojo.byId("buttonAllFotos");var bl=dojo.byId("bigfotoleft");var br=dojo.byId("bigfotoright");if(isFotosSmallDIVMinimized){b.src=imgButtonAlleFotos.src;bl.style.visibility="visible";br.style.visibility="visible";}else{b.src=imgButtonAlleFotosGrey.src;bl.style.visibility="hidden";br.style.visibility="hidden";}};function checkMenuOnClick(mi){var nh=1;for(var i=0;i<isMenuMinimized.length;i++){if(i==mi){continue;}if(!isMenuMinimized[i]){dojox.fx.wipeTo({node:"subMenu"+i,duration:500,height:1}).play();isMenuMinimized[i]=true;}}if(mi==-1){return;}if(menuHeight[mi]==0){return;}if(isMenuMinimized[mi]){nh=menuHeight[mi];}dojox.fx.wipeTo({node:"subMenu"+mi,duration:500,height:nh}).play();isMenuMinimized[mi]=!isMenuMinimized[mi];};function downloadActBigImg(){downloadBigImg(fotoBigRight,actualImgNo);};function downloadBigImg(_3,_4){if(_4<0||_4>=imageFile.length){return;}_3.src=getImageFile(_4);_3.width=imageFileWidth[_4];_3.height=480;};function downloadNextBigImg(){downloadBigImg(fotoBigRight,actualImgNo+1);};function downloadPrevBigImg(){downloadBigImg(fotoBigLeft,actualImgNo-1);};function downloadSmallImages(_5,to){var _6;var _7;for(var i=_5;i<=to&&i<imageFile.length;i++){if(!sImage[i]){sImage[i]=new Image();sImage[i].src=eventPath+"s"+imageFile[i];}}};function gbEditorOnKeyDown(){return true;if(window.event&&window.event.keyCode){var kc=window.event.keyCode;if(kc==13||kc==10){var _8=dojo.byId("gbeditordiv");_8.focus();var _9=_8.document.selection.createRange();_9.pasteHTML("<BR>");_8.focus();return false;}}return true;};function getImageFile(_a){return eventPath+imageFile[_a];};function getImageFileJSON(){dojo.xhrPost({url:eventPath+"getImageFile.php?g="+Math.random(),load:getImageFileCallback,error:getImageFileError,preventCache:true});};function getImageFileCallback(_b,_c){var _d=eval("("+_b+")");imageFile=_d.imgFile;imageFileWidth=_d.widths;getImageFileDone=true;afterLoadingGallery();};function getImageFileError(_e,_f){alert("Ein Fehler trat auf.... :-(");alert("data: "+_e.message);};function happyhourVisible(_10){if(_10){mainDivContainer.removeChild(rightContentPane);mainDivContainer.addChild(happyhourContentPane);}else{mainDivContainer.removeChild(happyhourContentPane);mainDivContainer.addChild(rightContentPane);}};function hitImage(){var fn=imageFile[actualImgNo];dojo.xhrPost({url:"hitImage.php",preventCache:true,content:{"g":Math.random(),"todo":"hit","fn":fn}});};function hitImageOnLoad(){alert("hit...");};function hitImageOnError(){alert("hit error");};function initializeImg(){for(var i=0;i<=39;i++){img[i]=dojo.byId("img"+i);}for(var i=0;i<=3;i++){imgt[i]=dojo.byId("imgt"+i);}for(var i=0;i<=39;i++){tdimg[i]=dojo.byId("tdimg"+i);}for(var i=0;i<=3;i++){tdimgt[i]=dojo.byId("tdimgt"+i);}for(var i=0;i<=9;i++){fotoRowTable[i]=dojo.byId("t"+i);}fotoBig=dojo.byId("fotoBig");fotoBigLeft=dojo.byId("fotoBigLeft");fotoBigRight=dojo.byId("fotoBigRight");};function initializeSmallImages(){var to=39;downloadSmallImages(0,to);setSmallImages(0);};function moveSmily(_11){var _12=dojo.byId("smily");var dy=dojo._abs(_11).y-dojo._abs(_12).y-7;dojox.fx.slideBy({node:"smily",duration:400,top:dy}).play();};function partyNewsLetterOnClick(){var el=dojo.byId("formpartynewsletter").elements;dojo.xhrPost({url:"partynewsletter.php",load:partyNewsLetterOnLoad,error:partyNewsLetterOnError,preventCache:true,content:{"g":Math.random(),"todo":"registrieren","vorname":escape(el["vorname"].value),"nachname":escape(el["nachname"].value),"email":escape(el["email"].value),"partyCB":el["partyCB"].checked,"fotoCB":el["fotoCB"].checked}});};function partyNewsLetterOnError(_13,_14){alert("es trat ein Fehler auf: "+_13.message);};function partyNewsLetterOnLoad(_15,_16){rightContentPane.attr("content",_15);};function scrollAllFotosToLeft(){for(var i=0;i<20;i++){if(i<imageFile.length){setSImg(img[i+20],img[i],i+20,tdimg[i].innerHTML);}else{setSImg(img[i+20],null,i+20);}}for(var i=0;i<5;i++){fotoRowTable[i+5].style.left=0;fotoRowTable[i].style.left=-dxFotosRow;}var di=actualFotoRow*4-20;for(var i=0;i<20;i++){setSImg(img[i],sImage[i+di],i,i+di+1);}fotosScrollAnimation=dojo.fx.combine([dojox.fx.slideBy({node:"t0",duration:500,left:dxFotosRow}),dojox.fx.slideBy({node:"t1",duration:500,left:dxFotosRow}),dojox.fx.slideBy({node:"t2",duration:500,left:dxFotosRow}),dojox.fx.slideBy({node:"t3",duration:500,left:dxFotosRow}),dojox.fx.slideBy({node:"t4",duration:500,left:dxFotosRow}),dojox.fx.slideBy({node:"t5",duration:500,left:dxFotosRow}),dojox.fx.slideBy({node:"t6",duration:500,left:dxFotosRow}),dojox.fx.slideBy({node:"t7",duration:500,left:dxFotosRow}),dojox.fx.slideBy({node:"t8",duration:500,left:dxFotosRow}),dojox.fx.slideBy({node:"t9",duration:500,left:dxFotosRow})]);fotosScrollAnimation.play();actualFotoRow-=5;};function scrollAllFotosToRight(){if(actualFotoRow+5>imageFile.length/4){return;}actualFotoRow+=5;var _17=(actualFotoRow+5)*4;downloadSmallImages(_17,_17+19);fotosScrollAnimation=dojo.fx.combine([dojox.fx.slideBy({node:"t0",duration:500,left:-dxFotosRow}),dojox.fx.slideBy({node:"t1",duration:500,left:-dxFotosRow}),dojox.fx.slideBy({node:"t2",duration:500,left:-dxFotosRow}),dojox.fx.slideBy({node:"t3",duration:500,left:-dxFotosRow}),dojox.fx.slideBy({node:"t4",duration:500,left:-dxFotosRow}),dojox.fx.slideBy({node:"t5",duration:500,left:-dxFotosRow}),dojox.fx.slideBy({node:"t6",duration:500,left:-dxFotosRow}),dojox.fx.slideBy({node:"t7",duration:500,left:-dxFotosRow}),dojox.fx.slideBy({node:"t8",duration:500,left:-dxFotosRow}),dojox.fx.slideBy({node:"t9",duration:500,left:-dxFotosRow})]);fotosScrollAnimation.onEnd=scrollAllFotosToRightOnEnd;fotosScrollAnimation.play();};function scrollAllFotosToRightOnEnd(){for(var i=20;i<39;i++){if(i<imageFile.length){setSImg(img[i-20],img[i],i-20,tdimg[i].innerHTML);}else{setSImg(img[i-20],null,i-20);}}for(var i=0;i<5;i++){fotoRowTable[i].style.left=0;fotoRowTable[i+5].style.left=dxFotosRow;}setSmallImages(actualFotoRow*4);};function scrollBigFotoToLeft(){if(!isFotosSmallDIVMinimized){return;}if(fotosScrollAnimation!=null&&fotosScrollAnimation.status()=="playing"){return;}if(actualImgNo<=0){return;}setActImgBorderToNormal();if(actualImgNo%4==0){actualImg=3;--actualImgNo;if(Math.floor(actualImgNo/4)==actualFotoRow-1){scrollFotosToLeft();}}else{--actualImg;--actualImgNo;}var dx=700+Math.floor((640-imageFileWidth[actualImgNo])/2);fotosScrollAnimation=dojo.fx.combine([dojox.fx.slideBy({node:"fotoBigLeft",duration:500,left:dx}),dojox.fx.slideBy({node:"fotoBig",duration:500,left:700})]);fotosScrollAnimation.onEnd=scrollBigFotoToLeftOnEnd;fotosScrollAnimation.play();hitImage();};function scrollBigFotoToLeftOnEnd(){setActImgBorderToActive();fotoBig.src=fotoBigLeft.src;fotoBig.width=fotoBigLeft.width;fotoBig.height=fotoBigLeft.height;fotoBig.style.left=fotoBigLeft.style.left;fotoBigLeft.style.left=-675;downloadPrevBigImg();downloadNextBigImg();};function scrollBigFotoToRight(){if(!isFotosSmallDIVMinimized){return;}if(fotosScrollAnimation!=null&&fotosScrollAnimation.status()=="playing"){return;}if(actualImgNo+1>=imageFile.length){return;}setActImgBorderToNormal();if(actualImgNo%4==3){actualImg=0;++actualImgNo;if(Math.floor(actualImgNo/4)==actualFotoRow+1){scrollFotosToRight();}}else{++actualImg;++actualImgNo;}var dx=-700+Math.floor((640-imageFileWidth[actualImgNo])/2);fotosScrollAnimation=dojo.fx.combine([dojox.fx.slideBy({node:"fotoBig",duration:500,left:-700}),dojox.fx.slideBy({node:"fotoBigRight",duration:500,left:dx})]);fotosScrollAnimation.onEnd=scrollBigFotoToRightOnEnd;fotosScrollAnimation.play();hitImage();};function scrollBigFotoToRightOnEnd(){setActImgBorderToActive();fotoBig.src=fotoBigRight.src;fotoBig.width=fotoBigRight.width;fotoBig.height=fotoBigRight.height;fotoBig.style.left=fotoBigRight.style.left;fotoBigRight.style.left=725;downloadPrevBigImg();downloadNextBigImg();};function scrollFotosToLeft(){if(fotosScrollAnimation!=null&&fotosScrollAnimation.status()=="playing"){return;}if(actualFotoRow<=0){return;}setActImgBorderToNormal();if(!isFotosSmallDIVMinimized){scrollAllFotosToLeft();return;}var t0=dojo.byId("t0");var tt=dojo.byId("tt");var di=actualFotoRow*4-4;for(var i=0;i<=3;i++){setSImg(imgt[i],sImage[i+di],-i,i+di+1);}tt.style.left=-dxFotosRow;fotosScrollAnimation=dojo.fx.combine([dojox.fx.slideBy({node:"tt",duration:500,left:dxFotosRow}),dojox.fx.slideBy({node:"t0",duration:500,left:dxFotosRow})]);fotosScrollAnimation.onEnd=scrollFotosToLeftOnEnd;fotosScrollAnimation.play();--actualFotoRow;};function scrollFotosToLeftOnEnd(){var t0=dojo.byId("t0");var tt=dojo.byId("tt");var di=actualFotoRow*4;setSmallImages(di);t0.style.left=0;tt.style.left=-dxFotosRow;};function scrollFotosToRight(){if(fotosScrollAnimation!=null&&fotosScrollAnimation.status()=="playing"){return;}if(actualFotoRow*4+4>=imageFile.length){return;}setActImgBorderToNormal();if(!isFotosSmallDIVMinimized){scrollAllFotosToRight();return;}var t0=dojo.byId("t0");var tt=dojo.byId("tt");var di=actualFotoRow*4+4;tt.style.left=dxFotosRow;tt.style.top=0;for(var i=0;i<=3;i++){if(i+di<imageFile.length){setSImg(imgt[i],sImage[i+di],-i,i+di+1);}else{setSImg(imgt[i],null,-i);}}fotosScrollAnimation=dojo.fx.combine([dojox.fx.slideBy({node:"tt",duration:500,left:-dxFotosRow}),dojox.fx.slideBy({node:"t0",duration:500,left:-dxFotosRow})]);fotosScrollAnimation.onEnd=scrollFotosToRightOnEnd;fotosScrollAnimation.play();++actualFotoRow;var _18=(actualFotoRow+9)*4;downloadSmallImages(_18,_18+3);};function scrollFotosToRightOnEnd(){var t0=dojo.byId("t0");var tt=dojo.byId("tt");var di=actualFotoRow*4;setSmallImages(di);t0.style.left=0;tt.style.left=dxFotosRow;};function setActImgBorderToActive(){if(actualImgNo==-1){return;}if(Math.floor(actualImgNo/4)==actualFotoRow&&isFotosSmallDIVMinimized){img[actualImgNo%4].style.borderColor="green";}else{if(!isFotosSmallDIVMinimized){img[actualImgNo%20].style.borderColor="green";}}};function setActImgBorderToNormal(){if(actualImgNo==-1){return;}if(Math.floor(actualImgNo/4)==actualFotoRow&&isFotosSmallDIVMinimized){img[actualImgNo%4].style.borderColor="#555555";}else{if(!isFotosSmallDIVMinimized){img[actualImgNo%20].style.borderColor="#555555";}}};function setBigFlyer(_19){var _1a=dojo.byId("bigFlyer");_1a.src=_19;};function setBigFoto(_1b){setActImgBorderToNormal();var _1c=parseInt(_1b.parentNode.parentNode.parentNode.parentNode.id.substring(1));actualFotosTable=_1c;actualFotoRow=actualFotoRow+parseInt(_1c);actualImg=parseInt(_1b.id.substring(3))%4;actualImgNo=actualFotoRow*4+actualImg;var _1d=(actualFotoRow+5)*4;downloadSmallImages(_1d,_1d+19);downloadActBigImg();var a=new Array();a.push(dojo.fadeOut({node:"fotoBig",duration:500,onEnd:setBigFotoFadeOutOnEnd}));var dy=_1c*122;if(_1c!=0){for(var i=_1c;i>=0;i--){a.push(dojox.fx.slideBy({node:"t"+i,duration:500,top:-dy}));}}if(!isFotosSmallDIVMinimized){a.push(dojox.fx.wipeTo({node:"fotosSmallDIV",duration:500,height:110}));}if(a.length!=0){var _1e=dojo.fx.combine(a);_1e.onEnd=setBigFotoOnEnd;_1e.play();}isFotosSmallDIVMinimized=true;checkFotosDIV();hitImage();};function setBigFotoFadeOutOnEnd(){setActImgBorderToActive();fotoBig.src=fotoBigRight.src;fotoBig.width=fotoBigRight.width;fotoBig.height=fotoBigRight.height;fotoBig.style.left=25+Math.floor((640-imageFileWidth[actualImgNo])/2);dojo.fadeIn({node:"fotoBig",duration:500}).play();downloadNextBigImg();downloadPrevBigImg();fotoBig.style.borderWidth=1;};function setBigFotoOnEnd(){if(actualFotosTable==0){return;}var tt=dojo.byId("tt");var di=actualFotoRow*4;for(var i=0;i<4;i++){if(i+di<imageFile.length){setSImg(imgt[i],sImage[i+di],-i,i+di+1);}else{setSImg(imgt[i],null,-i);}}tt.style.left=0;for(var i=1;i<5;i++){fotoRowTable[i].style.top=i*122;}setSmallImages(di);fotoRowTable[0].style.top=0;tt.style.left=-dxFotosRow;actualFotosTable=0;};function setContentHREF(doc,p){if(typeof p=="undefined"){rightContentPane.attr("href",doc+"?g="+Math.random());}else{rightContentPane.attr("href",doc+"&g="+Math.random());}};function setContentIMG(img){rightContentPane.attr("content","<IMG STYLE=\"position:absolute;left:100px;top:0px;\" SRC=\""+img+"\" />");};function setContentMap(doc){rightContentPane.onLoad=setContentMapOnLoad;rightContentPane.attr("href",doc+"?g="+Math.random());};function setContentMapOnLoad(e){var _1f=new SearchChMap({center:"Winterthur, Schauffhauserstr. 4"});_1f.set({center:"Winterthur, Schauffhauserstr. 4"});_1f.showPOIGroup("verkehr,bar");rightContentPane.onLoad=null;};function setSImg(_20,_21,i,no){if(_21==null||_21.src==null||_21.src.indexOf("null")!=-1){_20.src=null;_20.style.visibility="hidden";if(i>=0){tdimg[i].style.visibility="hidden";}else{tdimgt[-i].style.visibility="hidden";}return;}_20.src=downloadImg.src;_20.style.visibility="visible";_20.src=_21.src;_20.alt="Bild-Nr: "+no;if(i>=0){setSImgNo(tdimg[i],no);tdimg[i].style.visibility="visible";}else{setSImgNo(tdimgt[-i],no);tdimgt[-i].style.visibility="visible";}};function setSImgNo(_22,no){_22.innerHTML=""+no;};function setSmallImages(di){for(var i=0;i<=39;i++){try{if((i+di)<imageFile.length){setSImg(img[i],sImage[i+di],i,i+di+1);}else{setSImg(img[i],null,i);}}catch(err){alert("err: "+err.description);}}setActImgBorderToActive();};function showFotosOverwiev(){if(!isFotosSmallDIVMinimized){return;}setActImgBorderToNormal();var _23=actualFotoRow%5;var _24=actualFotoRow-_23;var dy=_23*122;for(var i=4;i>=0;i--){fotoRowTable[i].style.top=-(_23-i)*122;}isFotosSmallDIVMinimized=false;actualFotoRow-=_23;setSmallImages(_24*4);var a=new Array();if(_23!=0){for(var i=4;i>=0;i--){a.push(dojox.fx.slideBy({node:"t"+i,duration:500,top:dy}));}}a.push(dojox.fx.wipeTo({node:"fotosSmallDIV",duration:500,height:608,onEnd:showFotosOverwievOnEnd}));dojo.fx.combine(a).play();checkFotosDIV();};function showFotosOverwievOnEnd(){fotoBig.src=blackImg.src;fotoBig.style.borderWidth=0;};function showGallery(ep){eventPath="fotos/"+ep+"/";imageFile.length=0;sImage.length=0;imageFileWidth.length=0;img.length=0;imgt.length=0;tdimg.length=0;tdimgt.length=0;fotoRowTable.length=0;actualFotosTable=0;actualFotoRow=0;actualImg=0;actualImgNo=-1;isFotosSmallDIVMinimized=false;getImageFileDone=false;galleryLoadDone=false;showGalleryOnLoadOld=rightContentPane.onLoad;rightContentPane.onLoad=showGalleryOnLoad;rightContentPane.attr("href","fotos.html?g="+Math.random());getImageFileJSON();};function showGalleryOnLoad(e){galleryLoadDone=true;afterLoadingGallery();};function printObjectValues(obj){var _25="";var i=0;for(o in obj){_25+="\n\n"+o+" - "+obj[o];++i;if(i==5){i=0;alert(_25);_25="";}}alert(_25);};function printStatus(_26){alert(_26+"\ngetImageFileDone: "+getImageFileDone+"\ngalleryLoadDone: "+galleryLoadDone);};function dogugus2(){setContentHREF("guestbook.php?todo=listEntries2",true);return;};function dogugus(){setContentHREF("guestbook.php?todo=listEntries",true);return;};function doinsert(){var _27=dojo.byId("gbeditor2");_27.focus();document.execCommand("InsertImage",false,"smily/smilie_happy_008.gif");return;var gbe=dijit.byId("gbeditor");gbe.execCommand("inserthtml","allo <img src=\"smily/smilie_happy_008.gif\">");};function doinsert2(){var gbe=dijit.byId("gbeditor");gbe.execCommand("insertImage","smily/smilie_happy_008.gif");};function setBigDJ(no){var img=dojo.byId("imgbigdj"+no);var div=dojo.byId("divdj"+no);img.style.visibility="visible";div.style.visibility="visible";for(var i=1;i<=4;i++){if(i==no){continue;}var _28=dojo.byId("imgbigdj"+i);var _29=dojo.byId("divdj"+i);_28.style.visibility="hidden";_29.style.visibility="hidden";}};function gbNewEntryOnClick(){var el=dojo.byId("gbform").elements;dojo.xhrPost({url:"guestbook.php",load:gbNewEntryOnLoad,error:gbNewEntryOnError,preventCache:true,content:{"g":Math.random(),"todo":"saveNewEntry","user":escape(el["gbuser"].value),"passwort":escape(el["gbpasswort"].value),"message":escape(dojo.byId("gbeditordiv").innerHTML)}});};function gbNewEntryOnError(_2a,_2b){alert("es trat ein Fehler auf: "+_2a.message);};function gbNewEntryOnLoad(_2c,_2d){rightContentPane.attr("content",_2c);};function insert(src){var _2e=dojo.byId("gbeditordiv");_2e.focus();if(typeof _2e.document!="undefined"&&typeof _2e.document.selection!="undefined"){var _2f=_2e.document.selection.createRange();var _30="<img src=\""+src+"\">";_2f.pasteHTML(_30);if(!isgbsmiliesDivMinimized){gbZoomDivOnClick();}}else{alert("Das einf?gen der Smilies funktioniert zur Zeit nur im Microsoft IE");}};function gbZoomDivOnClick(){var _31=dojo.byId("gbzoomdiv");var _32=dojo.byId("gbsmiliesdiv");var nh=300;var dy=240;dojo.byId("gbeditordiv").focus();if(isgbsmiliesDivMinimized){}else{nh=60;dy=-240;}var a=new Array();a.push(dojox.fx.wipeTo({node:"gbsmiliesdiv",duration:500,height:nh}));a.push(dojox.fx.slideBy({node:"gbzoomdiv",duration:500,top:dy}));dojo.fx.combine(a).play();isgbsmiliesDivMinimized=!isgbsmiliesDivMinimized;};function isInputLeer(_33){if(dojo.byId("djform").elements[_33].value.replace(new RegExp("[ ]+","g"),"").length==0){return true;}return false;};function FApp(f,_34){f.v+="Feld \""+_34+"\" muss ausgef?llt werden.\n";};function djSendenOnClick(){var _35=new Object();_35.v="";if(isInputLeer("djvorname")){FApp(_35,"Vorname");}if(isInputLeer("djname")){FApp(_35,"Name");}if(isInputLeer("djstrasse")){FApp(_35,"Strasse");}if(isInputLeer("djplz")){FApp(_35,"PLZ");}if(isInputLeer("djort")){FApp(_35,"Ort");}if(isInputLeer("djemail")){FApp(_35,"eMail");}if(isInputLeer("djtelnr")){FApp(_35,"Telefon-Nr");}if(isInputLeer("djalter")){FApp(_35,"Alter");}var el=dojo.byId("djform").elements;if(!el["djtag[0]"].checked&&!el["djtag[1]"].checked&&!el["djtag[2]"].checked&&!el["djtag[3]"].checked){_35.v+="\n\nMindestens ein Tag muss ausgew?hlt werden.";}var _36=dojo.byId("djform").elements["djstatus"];if(!_36[0].checked&&!_36[1].checked&&!_36[2].checked){_35.v+="\n\nBitte ausw?hlen: profi, semi-profi oder newcomer!";}if(_35.v.length!=0){alert(_35.v);return;}if(!dojo.byId("djform").elements["djagb"][0].checked){alert("F?r die Anmeldung m?ssen die Wettbewerbsbedingungen gelesen und akzeptiert werden.");return;}dojo.xhrPost({url:"djwettbewerb.php",load:djSendenOnLoad,error:djSendenOnError,preventCache:true,form:dojo.byId("djform"),content:{"g":Math.random(),"todo":"newdj"}});};function djSendenOnError(_37,_38){alert("es trat ein Fehler auf: "+_37.message);};function djSendenOnLoad(_39,_3a){rightContentPane.attr("content",_39);};function djAGBvisible(_3b){var v="hidden";if(_3b){v="visible";}dojo.byId("djagbdiv").style.visibility=v;dojo.byId("djagbclosediv").style.visibility=v;};
