Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #1293989

    Hello,

    There seems to be an error with the Enfold Theme and the “Custom Product Tabs for WooCommerce” Plugin. There is too much space around the tab elements – it wasn’t always like that, but it seems one of the updates to Enfold caused the problem.

    I have included the link to one of the pages in question as well as the login to the site.

    #1294476

    Hey vantagepointmg,

    Thank you for the inquiry.

    For some reason, a lot of whitespaces are added around the tab title. We can remove those whitespaces by using this script in the functions.php file.

    function ava_trim_tab_title_whitespaces(){
    	?>
    <script>
    (function($) {
        $("#top div div.product .woocommerce-tabs ul.tabs li a").each( function() {
            var title = $(this).text();
            var trimmed = $.trim(title);
            $(this).html(trimmed);
        });
    }
    )(jQuery);
    </script>
    	<?php
    }
    add_action('wp_footer', 'ava_trim_tab_title_whitespaces');
    

    Best regards,
    Ismael

    #1294583

    Hello Ismael,

    Thanks for the reply back, however it seems that the code has some errors. When I added it to the PHP files, the website came back with this error:

    502
    The page request was canceled because it took too long to complete
    What can I do?

    Site visitors: There was an issue serving your request, please try again in a few minutes.

    Site Owners: A request for either a page, script, process, or query has taken too long to complete and has been cancelled due to a bad gateway. You should visit your error log for more information.

    Please advise.

    #1295065

    Hi,

    Thank you for the update.

    The code works fine on our end, no errors. Did you copy the snippet from your email? Please try to copy it directly from this forum instead.

    We also noticed that the site contains a very old version of the theme, v4.4.1. You have to upgrade the theme to latest version (v4.8.1) first.

    Best regards,
    Ismael

    #1299009

    That worked! Thank you so much :)

    #1299261

    Hi,

    Awesome! Glad that worked. Please feel free to open another thread if you need anything else. We will close this one for now.

    Have a nice day.

    Best regards,
    Ismael

Viewing 6 posts - 1 through 6 (of 6 total)
  • The topic ‘"Custom Product Tabs for WooCommerce" Plugin Display Problem’ is closed to new replies.