Tagged: x
-
AuthorPosts
-
February 16, 2017 at 12:24 pm #1373903
Tristan AParticipantHi there,
I am trying to use the code from this thread to hide the Woo cart when empty.
https://community.theme.co/forums/topic/showhide-ajax-cart/
It doesn’t seem to work, unfortunately….
All help appreciated!
February 16, 2017 at 12:25 pm #1373904
Tristan AParticipantThis reply has been marked as private.February 16, 2017 at 10:11 pm #1374494
Rue NelModeratorHello There,
Thanks for writing in! The code isn’t working because you have a different setting. With you current settings, you should make use of this code instead:
(function($) { var element = $('.x-cart .outer'); if(element.html() == "0 Items") { $('.x-menu-item-woocommerce').css('display','none'); } element.on('change', function(){ if(element.html() == "0 Items") { $('.x-menu-item-woocommerce').css('display','block'); } }); })(jQuery);We would loved to know if this has work for you. Thank you.
February 17, 2017 at 6:56 am #1374896
Tristan AParticipantThanks! It worked!
February 17, 2017 at 9:04 am #1375056
RahulModeratorGlad to hear it!
Feel free to ask us again. 🙂
-
AuthorPosts
- <script> jQuery(function($){ $("#no-reply-1373903 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>
