Mobile off canvas trigger issue on masseriasantalachicca.com

#815404
  • Resolved Ingigni
    Rank Math free

    Dear support,
    when the Rank Math plugin is enabled, on the mobile version of the website, the burger icon which triggers the off canvas containing the mobile menu does not work.

    Could you help, please?

    Thanks in advance.

    Kind regards,
    Liborio Fedele

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hello,

    I apologize for the issue you are facing with the mobile off-canvas trigger on your website when Rank Math is enabled. To resolve this problem, you can try the following steps:

    1. Open your theme’s functions.php file.
    2. Add the provided code snippet to the functions.php file to make the off-canvas trigger work correctly with Rank Math enabled.
    
    /**
     * Convert Rank Math FAQ Block Into Accordion
     */
    function turn_rm_toc_collapsable() {
        ?>
    
            jQuery(document).ready(function() {
                var tocItems = jQuery("div.wp-block-rank-math-toc-block");
                tocItems.bind("click", function(event) {
                    var nav = jQuery(this).find("nav");
                    if (nav.css("overflow") == "hidden") {
                        nav.css("overflow", "visible");
                        nav.css("max-height", "100vh");
                    } else {
                        nav.css("overflow", "hidden");
                        nav.css("max-height", "0");
                    }
                });
            });

    Sources:
    WooCommerce Products Page is Misaligned When Using Rank Math
    This Plugin Does Not Work with Your Version of PHP » Rank Math
    How to Add Rank Math’s Table of Contents Block » Rank Math

    Hello,

    Thank you for contacting us and sorry for any inconvenience that might have been caused due to that.

    We checked your website and we can see the menu icon works properly on mobile devices even when the Rank Math plugin is activated. Please check this screencast for your reference: https://i.rankmath.com/v/dzn7e1

    If you’re still facing the issue on your website, please share a screencast with us by using a tool like https://loom.com so that we can check this further for you.

    Looking forward to helping you.

    Thank you.

    Ingigni
    Rank Math free

    Hello,
    I checked further and realized the issue was related to the caching plugin I wrongly set.

    Now everything works fine.

    Thanks for your help, and sorry.

    Hello,

    We are glad that you have found the culprit of this issue, and it is already resolved.

    Please feel free to reach out to us again in case you need any other assistance.

    We are here to help.

    Thank you.

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

You must be logged in to reply to this ticket.