Forum Replies Created

Viewing 11 replies - 16 through 26 (of 26 total)
  • Thread Starter kkj

    (@kkj)

    No worries, thank you for getting back to me!
    Actually, I had tried dequeing before, but it did not work for some of the wooscripts. I tried

    add_action('wp_enqueue_scripts', 'woo_scriptcleaner', 101);
    function woo_scriptcleaner() {
    remove_action( 'wp_head', array( $GLOBALS['woocommerce'], 'generator' ) );
    
        if(class_exists('woocommerce')) {
        if(!is_product() and !is_checkout() and !is_cart() ) {
                wp_dequeue_script('wcqi-js');
                wp_dequeue_script('wc-add-to-cart');
                wp_dequeue_script('select2');
                wp_dequeue_script('jquery-blockui');
                wp_dequeue_script('jquery-cookie');
                wp_dequeue_script('woocommerce');
                wp_dequeue_script('wc-cart-fragments');
                wp_dequeue_script('wc-country-select');
                wp_dequeue_script('wc-address-i18n');
                wp_dequeue_style('select2');  
    
     }}}

    but some of the scripts did not get dequeued, like country select or blockUI. Is this not possible? It pnly seems to work with deregister, but then you get the errors.

    Thread Starter kkj

    (@kkj)

    I can’t, but all the scripts I deregistered(all Woo scripts and the two above mentioned from the theme) are sending that, and they all refer to
    wordpress/wp-includes/class.wp-scripts.php on line 250

    Thread Starter kkj

    (@kkj)

    Hi, just getting back to you, while this is working great, I am now receiving multiple errors in debug log saying “Undefined index” and “Trying to get property of non-object”…is there a way to fix this?
    Thank you.

    Thread Starter kkj

    (@kkj)

    I found a subtitle plugin that is working. Thank you though.

    Thread Starter kkj

    (@kkj)

    Yes, I will use caching in the future, I just thought it might help to deregister on the pages where not needed so there would be even less to minify and combine.
    Thanks though!

    Thread Starter kkj

    (@kkj)

    Yes! This is working! Thank you. I also included woocommerce js and css to only load on the shop pages, would you by chance know where to look for explanation on what each js file from woocommerce is used for? Maybe I don’t need all of them either, like “select2.js”. Then I would deregister them completely like the add-to-cart-variation.

    Thread Starter kkj

    (@kkj)

    Actually I tried this but the files are not loaded anywhere now..not on the cart, not on the checkout…are you sure this is correct?

    Thread Starter kkj

    (@kkj)

    Thank you! Just wondering: Is the add-to-cart-variation js needed if I donn’t sell any products with variations so I could just remove the link completely? Or would I still need to have it on the shop pages?

    Thread Starter kkj

    (@kkj)

    Yes, I tried Zencache and Hypercache, also W3 and Cachify. Basically the same as WPFC, what I don’t like about some of them is that they don’t have the option to only have the blog post refreshed when a new post is creaated(the whole cache gets emptied).
    I was also wondering, is AO creating files for logged in users(just me, the admin and author)? And please tell me what the files are that are also added in the autoptimize main cache folder(not the js or css folder).

    Thread Starter kkj

    (@kkj)

    thank you for your offer, I’ll get back to that. Currently I am also trying to figure out which caching plugin to use in first place. I read you recommend Super Cache, I have also tried that but again subjectively it seems fast but webpagetest says different. And togethre with AO it’s even slower…when Super cache’s cache is emptied, is AO#s cache also getting emptied?
    May I also ask if you are using the preload function of Super cache? I would really love to use AO but the first load is taking forever and I don’t want the first visitor see this.

    Thread Starter kkj

    (@kkj)

    Hello,
    well my site is not open to public yet but I did 5 tests each on webpagetest and there, I found similar results. I have some screen shots:

    https://www.dropbox.com/s/55mjei5dlccazqm/test1.JPG?dl=0
    https://www.dropbox.com/s/ywcwf3qhwzz8zzi/test2.JPG?dl=0

    https://www.dropbox.com/s/w3aomwf5nus68ev/testwpfc1.JPG?dl=0
    https://www.dropbox.com/s/thyvf5oi493nzpe/WPFC2.JPG?dl=0

    the first two are with AO, the other with WPFC.
    On Gmetrix though I get 2.6-3 s on average with WPFC and 3.6-4s with AO.

Viewing 11 replies - 16 through 26 (of 26 total)