Jump to content

How to fade out Add to cart Pop up in prestashop 1.6.1.3 default theme


Zen_j1

Recommended Posts

Hello can some help to fade out add to cart popup after 3 sec in prestashop 1.6.1.3 default theme so customer can continue shopping. At this time pop up show confirmation with continue shopping and checkout it stay there till closes it this need to be done for every product. I need popup to fade out in 3 sec.  

Link to comment
Share on other sites

/themes/default-bootstrap/js/modules/blockcart/ajax-cart.js, from line 731

updateLayer : function(product){
    $('#layer_cart_product_title').text(product.name);
    $('#layer_cart_product_attributes').text('');
    if (product.hasAttributes && product.hasAttributes == true)
        $('#layer_cart_product_attributes').html(product.attributes);
    $('#layer_cart_product_price').text(product.price);
    $('#layer_cart_product_quantity').text(product.quantity);
    $('.layer_cart_img').html('<img class="layer_cart_img img-responsive" src="' + product.image + '" alt="' + product.name + '" title="' + product.name + '" />');

    var n = parseInt($(window).scrollTop()) + 'px';

    $('.layer_cart_overlay').css('width','100%');
    $('.layer_cart_overlay').css('height','100%');
    $('.layer_cart_overlay').show();
    $('#layer_cart').css({'top': n}).fadeIn('fast');
    crossselling_serialScroll();

    // ADD THIS
    setTimeout(function() {
        $('.layer_cart_overlay').hide();
        $('#layer_cart').fadeOut('slow');
    }, 3000);
},

 

  • Like 2
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...