fancybox.close() and open another fancybox -


is first time i'am using forum.

my problem want close fancybox open fancybox. , using in code parent.$.fancybox.close() close fancybox iframe window. when user click in add cart button. fancybox close , program in js stop running. example:

$(x).click(function(){     parent.$.fancybox.close();        idcombination = $('#idcombination').val();     $.ajax({         type: "post",         url: baseuri + '?rand=' + new date().gettime(),         data: 'controller=cart&add=1&ajax=true&qty=' + $('#quantity_wanted').val() + '&id_product=' + id_product + '&token=' + static_token + ( (parseint(idcombination) && idcombination != null) ? '&ipa=' + parseint(idcombination): ''),         beforesend: function() {             $('#loading_img').show();         },         success: function(q) {             $.ajax({                 type: "post",                 url: path + "ajaxcart/pop_up.php",data:'referer='+document.referrer,                 beforesend: function() {                     $(".shop").show();                     $('#loading_img').show();                 },                 success: function(res) {                     $(".shop").show();                     $("#shopping").show();                     $('#loading_img').hide();                     $('#shopping').html(res);                 }             });         }     });     $("html, body").animate({scrolltop: 300}, "slow");     return false; }); 


Comments

Popular posts from this blog

sublimetext3 - what keyboard shortcut is to comment/uncomment for this script tag in sublime -

java - No use of nillable="0" in SOAP Webservice -

ubuntu - Laravel 5.2 quickstart guide gives Not Found Error -