function submitOrderForm(){var d;var a=[];var c={frm_name:"Name",frm_email:"Email",frm_phone:"Phone",frm_date:"Event Date",frm_zip:"Zip code"};for(var b in c){d=document.getElementById(b).value.length;if(d<4){a.push(c[b])}}if(a.length>0){var e="Please complete the following fields:\n\n\t-";e+=a.join("\n\t-");alert(e)}else{submitTheForm()}}function submitTheForm(){for(var f in shoppingCart){var a=shoppingCart[f].opts;for(var d=0;d<a.length;d++){shoppingCart[f].opts[d]=pieceOptionsArray[a[d]].name}shoppingCart[f].total+=getInksCost(shoppingCart[f])}var e,b,j;var g=["name","phone","email","date","zip","refer","description","lines","comments"];var k=["send","contact"];var h="cart_contents="+JSON.stringify(shoppingCart)+"";for(b=0;b<g.length;b++){e=document.getElementById("frm_"+g[b]).value;h+="&"+g[b]+"="+e}for(j=0;j<k.length;j++){e=(document.getElementById("frm_"+k[j]).checked)?("Yes"):("No");h+="&"+k[j]+"="+e}h+="&total="+shoppingCartTotal+"&inks="+numInks;h+="&design="+getCurrentDesign();ajaxRequest(configObj.relhome+"/php/custom_printing_form_submit.php",{params:h,endfunc:"display_submission_result(req.responseText);"});$("#information").hide();$("#thankyou").show();clearCart()}function display_submission_result(a){};