GIF89a
function saveAlert(prod_id,ops) { if (window.XMLHttpRequest) { xmlhttp = new XMLHttpRequest(); } else { xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); } xmlhttp.onreadystatechange=function() { if (this.readyState==4 && this.status==200) { if(this.responseText==1) { window.location.href = ("addremoveproduct.php"); } else if(this.responseText==0) { alert("Unable to add product in alert, please contact to developers") } } }; xmlhttp.open("GET","saveAlert.php?prod_id="+prod_id+"&ops="+ops,true); xmlhttp.send(); }