• It’s been a week and nothing has been resolved, and I’m really annoyed.

    My biggest problem is that the sidebar cart that pops up after adding a product has no plus and minus signs. You have to go back to the homepage and refresh to see them. Moreover, the addition and subtraction numbers in the sidebar cannot be synchronized to the shopping cart page. These two are the biggest problems.

    Another problem is your template’s built-in “Open Add to Cart on AJAX” function, when I open it, the front end does not display anything, but in the editor, it pops up normally, what’s going on?

    At present, it is a call written by myself, and the “Open on AJAX Add to Cart” that comes with the template is not used.

    function open_mini_cart_on_add_to_cart() {
         if ( ! (is_cart() || is_checkout()) ) {
             // If it's not a cart or checkout page, add javascript code to automatically open the mini cart on page refresh
             echo '<script>
                 jQuery(document). ready(function($) {
                     // Check if there is an "add_to_cart_clicked" key in localStorage
                     if (localStorage. getItem("add_to_cart_clicked")) {
                         // Add show class to show mini cart if present
                         $(".botiga-side-mini-cart").addClass("show");
                         $(".botiga-quantity-minus").addClass("show");
                         $(".botiga-quantity-plus").addClass("show");
                         // Then remove the key so that the next time the page is refreshed it won't automatically open the mini cart again
                         localStorage. removeItem("add_to_cart_clicked");
                     }
                   
                     // Listen for the click event of the "Add to cart" button
                     $(".single_add_to_cart_button").on("click", function() {
                         // store the "add_to_cart_clicked" key in localStorage when clicked
                         localStorage.setItem("add_to_cart_clicked", "true");
                     });
                 });
             </script>';
         }
    }
    add_action('wp_footer', 'open_mini_cart_on_add_to_cart');

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Hello,

    Please get in touch with us on our website. Since you are a Botiga Pro user, we cannot provide support here.

Viewing 1 replies (of 1 total)
  • The topic ‘The purchased paid version “Open on AJAX Add to Cart” function cannot be used.’ is closed to new replies.