WordPress.org

Ready to get started?Download WordPress

Forums

[Plugin: W3TC] minify googleapis jquery bad idea? (1 post)

  1. Everton
    Member
    Posted 3 years ago #

    Hi

    I've added the following to my theme functions to replace wordpress's jquery with google apis:

    Function register_google_cdn_jquery() {
    wp_deregister_script('jquery');
    wp_register_script('jquery', 'http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js');
    wp_enqueue_script('jquery');
    }
    add_action('init', 'register_google_cdn_jquery');

    After doing this, should I not combine/minify this in W3TC to get the maximum benefit when a user already has the file cached locally? Or if I combine it in W3TC, will the local version still get used if available?

    Thanks

    EB

Topic Closed

This topic has been closed to new replies.

About this Topic