I have just finished a website and the link is http://techuire.com/portfolio/BlotHub/
The problem with this website is that the jQuery is not working on safari browser at all. The jQuery is not working on Chrome in MAC either.
How to test? Please open the above link on Chrome in a PC and then do the same on Chrome in MAC, or Safari. Go to combo deals and click on Add to Cart. The left side cart will not update on the later OS and Browsers. But will be loaded on Chrome in Windows PC.
I am mentioning my code for reference. This code gets executed when a user clicks on the "Add to Cart" Button
<script type="text/javascript">
$(document).ready(function(){
$('.add_to_cart').click(function(){
var product_id= $(this).attr("id");
var product_name= $('#name'+product_id).val();
var product_price= $('#price'+product_id).val();
var product_image= $('#image'+product_id).val();
var product_quantity= $('#quantity'+product_id).val();
//alert(product_price);
$.ajax({
url:"includes/add_to_cart.php",
method:"POST",
data:{
product_id:product_id,
product_name:product_name,
product_price:product_price,
product_image:product_image,
product_quantity:product_quantity,
},
success: function(value)
{
swal("Success!", "Product added into cart!", "success");
setInterval(function(){
var quantity_id= $('#quantity_id').val();
$('.quantity123').load("includes/fetch_quantity.php?id=" + $('#quantity_id').val()).fadeIn("slow");
},500);
}
});
});
setInterval(function(){
$('.popupcart').load("includes/fetch.php").fadeIn("slow");
//use in header pop_up_page
},500);
$('.add_to_cart').click(function() {
location.reload();
});
setInterval(function(){
$('.cart_products').load("includes/fetch.php").fadeIn("slow");
//use in header pop_up_page
}, 1000);
});
</script>
"add_to_cart.php" just returns some values from the database, that code is not relevant to this query.
Thanks in anticipation