Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1379506
    timrooke1991
    Participant

    Hi,

    I want to add this plugin to speed up my site. When I do, it makes the site very fast. However, it completely breaks my Superfly menu. It prevents it from showing at all.

    Is there a way around this? The pluging states only works if you have plugins and a theme that utilizes wp_enqueue_scripts correctly. Does X Theme do this?

    Failing this, is there a way to do something similar?

    Thanks,

    Tim

    #1379624
    Christian
    Moderator

    Hey Tim,

    X does use wp_enqueue_scripts and the rest of WordPress best practices. You’re having an issue with Superfly though which does not have an option to load scripts in the footer. That doesn’t mean it is badly coded. It means it needs some scripts in the head. It could be technically possible to achieve that but would require custom development which is outside the scope of our support. You might want to contact our trusted partners who caters X setup and customization needs. Please see https://community.theme.co/custom-development/

    Thanks.

    #1379648
    timrooke1991
    Participant

    Okay, understood.

    Could you tell me the script slugs that Superfly requires to be in the header?

    I can set this to be ignored by the plugin – with the filter below

    add_filter( 'stf_exclude_scripts', 'jdn_header_scripts', 10, 1 );
    function jdn_header_scripts( $scripts ) {
        $scripts[] = 'backbone'; // Replace 'backbone' with the script slug
        return $scripts;
    }

    Thanks,

    Tim

    #1379717
    Lely
    Moderator

    Hello Tim,

    We can find it here:\wp-content\plugins\superfly-menu-folder\main.php.
    There are mutiple enqueue scripts there like : sf_scripts.

    Hope this helps.

    #1379748
    timrooke1991
    Participant

    Could you tell me the syntax for adding sf_scripts to the filter plugin?

    I have identified enqueue scripts, but unsure of how to reference this in the filter function.

    Thanks,

    Tim

    #1379921
    Christian
    Moderator

    We’re sorry but this would be under custom development. You might want to contact our trusted partners who caters X setup and customization needs. Please see https://community.theme.co/custom-development/

    Thanks.

  • <script> jQuery(function($){ $("#no-reply-1379506 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>