• Resolved dusint

    (@dusint)


    Hello, due to regulations I have to delete the button on the last Woocommerce checkout-page. It doesn’t work with Page ID. .thwmscf-buttons .thwmscf-cart-url. Do you have a solution?

Viewing 5 replies - 1 through 5 (of 5 total)
  • Dina S.

    (@themehighsupport)

    We are a little bit unclear about your exact issue. Could you please let us know whether you are trying to hide the Back to cart button from the last step?

    Thank you!

    Thread Starter dusint

    (@dusint)

    Exactly only at the last step. In Germany it is not allowed to go back to the shopping cart as a final step.

    Dina S.

    (@themehighsupport)

    Could you please check after adding the below code in your child theme’s functions.php file?

    add_action( 'wp_footer', 'th_hide_back_to_cart_button' );
    function th_hide_back_to_cart_button(){
        if(is_checkout()){
        ?>
            <script type="text/javascript">
                (function($){
                    $('#action-next').click(function(){
                        setTimeout(function(){
                            if($('.thwmscf-accordion-label.active').hasClass('last')){
                                $('.thwmscf-cart-url').hide();
                            }
                        },100);
                    })
                    $('#action-prev').click(function(){
                        $('.thwmscf-cart-url').show();
                    })
                    $('#thwmscf-tabs').find('li.thwmscf-tab a').click(function(){
                        setTimeout(function(){
                            if($('.thwmscf-accordion-label.active').hasClass('last')){
                                $('.thwmscf-cart-url').hide();
                            } else {
                                $('.thwmscf-cart-url').show();
                            }
                        },100);
                    });
                })(jQuery);
            </script>
        <?php
        }
    }

    Thank you!

    Thread Starter dusint

    (@dusint)

    Thanks for the answer!

    Unfortunately the code doesn’t work. Is there an alternative?

    I used the Travelerwp theme (https://travelerwp.com/).

    Dina S.

    (@themehighsupport)

    Hi,

    Your issue needs a detailed check. Can you please raise a ticket through our website? We hope our technical team will be able to help you.

    Thank you!

Viewing 5 replies - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.