• Resolved fnfweb

    (@fnfweb)


    Hello,

    When using WooCommerce and clicking on a product, this plugin being activated automatically appends an anchor link to the product tabs section of the page on load. So for instance, the URL should be:

    /shop/amor/

    but it becomes

    /shop/amor/#tab-additional_information

    Deactivating the plugin stops this effect.

    Doing reserach on this topic and isolating what was causing it, I found this, which might help for a solve.
    https://ww.wp.xz.cn/support/topic/breaks-tabs-on-woocommerce-products/

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

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Support Michael Beckwith

    (@tw2113)

    The BenchPresser

    Gimme a chance to do some research/tinkering and I’ll get back to you. I have some leads on ideas, but need to confirm feasibility.

    Thanks.

    Thread Starter fnfweb

    (@fnfweb)

    Thank you! Love the plugin!

    Plugin Support Michael Beckwith

    (@tw2113)

    The BenchPresser

    So the biggest issue is that, as you’ve noted, they use hashed anchor links, which is what our plugin is all about, so to speak.

    Part of our plugin allows for preventing acting on links, by adding a no-scroll class to a given link. I have checked WooCommerce’s template files, and am sadly not seeing any filters around the topic of classes for each tab. Not sure if your active theme already overrides the “tabs.php” template file, or if you’d be willing to yourself to add the classes.

    That said, I do have this following snippet that is worth trying, to dynamically add the no-scroll class to the tab links.

    <script>
    	jQuery('.wc-tabs li a').each(function (i, item) {
    		jQuery(this).addClass('no-scroll');
    	});
    </script>
    

    Give it a go, and let me know if it proves successful or if some more help is needed yet.

    Thread Starter fnfweb

    (@fnfweb)

    That fixed it! Thank you!

    Wonderful support – appreciate it!

    Thread Starter fnfweb

    (@fnfweb)

    Solved

    Plugin Support Michael Beckwith

    (@tw2113)

    The BenchPresser

    Awesome, thanks for helping confirm.

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘Breaks WooCommerce Pages’ is closed to new replies.