GIF89a php
Current File : /home/hencockfreshchic/public_html/admin.cpanel/uploadjs/removeImage.js
function removeImage(sr,ops,img){
	// ops 1 for image deletion 
	// ops 2 for product video id deletion

if(ops==1){
	if (window.XMLHttpRequest) {
            // code for IE7+, Firefox, Chrome, Opera, Safari
            xmlhttp = new XMLHttpRequest();
        } else {
            // code for IE6, IE5
            xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
        } 
  xmlhttp.onreadystatechange=function() 
   {
    if (this.readyState==4 && this.status==200) 
	{
		if(this.responseText==1){
			alert("The selected image has been removed");
			window.location.href = ("multipleimgform.php");
		}
		else
		{
			alert("Unable to delete the Product image | Contact to developers");
			window.location.href = ("multipleimgform.php");
		}
     
	}
  };
  xmlhttp.open("GET","removeImage.php?sr="+sr+"&image="+img,true);
  xmlhttp.send();
}


if(ops==2){
	if (window.XMLHttpRequest) {
            // code for IE7+, Firefox, Chrome, Opera, Safari
            xmlhttp = new XMLHttpRequest();
        } else {
            // code for IE6, IE5
            xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
        } 
  xmlhttp.onreadystatechange=function() 
   {
    if (this.readyState==4 && this.status==200) 
	{
      if(this.responseText==1){
			alert("The selected product has been deleted");
			window.location.href = ("product_video.php");
		}
		else
		{
			alert("Unable to remove the selected Video id");
			window.location.href = ("product_video.php");
		}
	}
  };
  xmlhttp.open("GET","removeVideoid.php?sr="+sr,true);
  xmlhttp.send();
}


}