• Resolved Mansi Shah

    (@daredevil22)


    Hi,

    Using v1.1.2 & in your changelog

    register stylesheet and JS and call only on KBE pages & only eneque and load search inline script if search is enabled

    For style ‘kbe_theme_style’ & script ‘kbe_live_search’, plugin has just enqueued styles & scripts without checking if the style is registered. This is causing a slight delay of loading CSS on KB pages which is looking bad on my site.

    To fix that, I need to manually edit all the plugin files & it is time consuming.
    Can you please make sure to include it in your upcoming release ASAP??

    https://wordpress.org/plugins/wp-knowledgebase/

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

    (@jonathan1996)

    Change the function kbe_styles() in wp-content\plugins\wp-knowledgebase\wp-knowledgebase.php to:

    function kbe_styles(){
    if( file_exists( get_stylesheet_directory() . ‘/wp_knowledgebase/kbe_style.css’ ) ){
    $stylesheet = get_stylesheet_directory_uri() . ‘/wp_knowledgebase/kbe_style.css’;
    } else {
    $stylesheet = WP_KNOWLEDGEBASE. ‘template/kbe_style.css’;
    }
    wp_register_style(‘know-style’, $stylesheet);
    wp_enqueue_style(‘know-style’);
    }
    add_action(‘wp_enqueue_scripts’, ‘kbe_styles’);

    Thread Starter Mansi Shah

    (@daredevil22)

    Thanks @jonathan1996 🙂

    But I really look forward to developer fix this problem in next release.

    Plugin Contributor Maeve Lander

    (@enigmaweb)

    Sorry about this. Fixed in 1.1.4. Thanks guys.

    Thread Starter Mansi Shah

    (@daredevil22)

    Thank you for the fix 🙂

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Scripts & Styles delay in loading’ is closed to new replies.