wk= new Array(); function delSession(AID) { frames[0].location.href="../delsession.php?id="+AID; if (AID=="wk") { wk=""; dispWK(); } } function add2WK(AID, AEd, ANum, APreis) { ANum=Number(ANum); if (isNaN(ANum)) ANum=0; s=AID+"_"+AEd+"_"+ANum+"_"+APreis; c=AID+"_"+AEd+"_"; found=-1; for (i=0; i-1) { wk[found]=s; } else { wk[wk.length]=s; } window.frames[0].location.href="../add2wk.php?id="+AID+"&anz="+ANum+"&ed="+AEd+"&preis="+APreis; dispWK(); } function formatCurr(ACurr) { if (ACurr==0) return ''; //if (Math.floor(ACurr)==ACurr) return "€ "+ACurr; i=Math.round(ACurr*100); s=String(i); s=s.substr(0,s.length-2)+','+s.substr(s.length-2,2); return "€ "+s; } function dispWK() { var i=0; anz=0; sum=0; s=""; for (i=0; i 0) { $("#linkWK"+a[0]).attr("href","wk.php"); $("#btnWK"+a[0]).attr("src","../img/wk_full.gif"); } } if (anz) { s="Warenkorb "+anz+" Artikel im Warenkorb ("+formatCurr(sum)+") anzeigen"; $("#wk_container").html(s); $("#menuSpacerLeft").attr("width",2); $("#menuCell").attr("align","left"); $("#menuSpacerRight").attr("width",""); } else { $("#wk_container").html(""); $("#menuSpacerLeft").attr("width",150); $("#menuCell").attr("align","center"); $("#menuSpacerRight").attr("width",150); } if ($("#wkSum").length > 0) $("#wkSum").html(formatCurr(sum)); } function rememberFormData(kat,e) { frames[0].location.href="../remember.php?kat="+kat+"&var="+e.name+"&val="+e.value; } function checkEmail(s) { var filter = /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/; return (filter.test(s)); }