function putintocart(itemID) { var itemhandle= new Ajax; var randvali=Math.floor(Math.random()*1000000000); var temp="anz_"+itemID; itemhandle.url="http://www.ism-parts.com/incs/ajax/putintocart.php"; itemhandle.params="rand="+randvali+"&itemID="+itemID+"&anz="+document.getElementById(temp).value; // alert(itemhandle.params); itemhandle.onSuccess=successItemHandler; itemhandle.onError=errorItemHandler; itemhandle.doRequest(); } function errorItemHandler(msg) {} function successItemHandler(txt, xml) { // alert(txt); var temp = txt.split("|||"); var help="anz_"+temp[3]; document.getElementById('korbinfo').innerHTML=temp[0]; document.getElementById('buttondiv').innerHTML=temp[4]; document.getElementById(help).value=1; if (temp[2]>0) alert (""); } function schnellbestellung(artikelNr,anzahl,rowID) { var quickhandle= new Ajax; quickhandle.url="http://www.ism-parts.com/incs/ajax/schnellbestellung.php"; quickhandle.params="artikelID="+artikelNr+"&anzahl="+anzahl+"&rowID="+rowID; // alert(itemhandle.params); quickhandle.onSuccess=successQuickHandle; quickhandle.onError=errorQuickHandle; quickhandle.method="POST"; quickhandle.doRequest(); } function errorQuickHandle(msg) {} function successQuickHandle(txt, xml) { // alert(txt); var temp = txt.split("|||"); var row=temp[3]; var summe=0; eval("document.getElementById('einzelpreis"+row+"').innerHTML=temp[1];"); eval("document.getElementById('gesamtpreis"+row+"').innerHTML=temp[2];"); if (temp[0]=="Artikel nicht gefunden.") { eval("document.form1.artikelnr_"+row+".value=document.form1.artikelnr_"+row+".value+' - ';"); eval("document.form1.artikelnr_"+row+".className='inputerror';"); } }