• Resolved cag8f

    (@cag8f)


    Hello. On my site I have Jetpack enabled, and I see a particular JS file loaded from wp.stats.com, initiated by Jetpack (screenshot). Can I ask what exactly this JS file does?

    As a test, in Jetpack–>Settings, in the “Site Stats” section, I disabled “Put a chart showing 48 hours of views in the admin bar.” But the JS file still loads.

    If it is not necessary, I would like to prevent the page from loading it (if possible).

    Thanks.

    The page I need help with: [log in to see the link]

Viewing 12 replies - 1 through 12 (of 12 total)
  • Plugin Support darnelldibbles

    (@darnelldibbles)

    Hi there,

    That appears to be the track script. It is used to track user visits.

    Are you trying to deactivate the entire stats module? If so, here is our support page to assist you with this:

    https://jetpack.com/support/module-overrides/

    Hope this helps.

    Thread Starter cag8f

    (@cag8f)

    Thanks for the reply.

    >> That appears to be the track script. It is used to track user visits.

    OK thanks. So if I prevent this script from loading, user visits will not be tracked–is that correct?

    >> Are you trying to deactivate the entire stats module?

    I’m not sure. What I want is this: in an effort to improve page load speed, I’m thinking about preventing this script from loading. But before I do that, I want to first figure out what will happen if I prevent the script from loading, and *how* exactly I would prevent the script from loading. We’re on our way to answering the first question.

    But what about the second question: what is the proper way to prevent this script from loading? I saw the page you linked, but I’m still unclear. That page describes modules which have a section in the Jetpack UI, and that can be toggled in the Jetpack UI. Can ‘track user visits,’ or ‘track stats’ in general, be toggled in the Jetpack UI? If so, maybe I can simply accomplish what I want with that toggle? I don’t think I saw it, but I could have missed it. I see a “Site Stats” section in the UI, but I don’t see any kind of toggle to turn stat collection on or off.

    Thanks.

    • This reply was modified 5 years, 12 months ago by cag8f.
    Plugin Support darnelldibbles

    (@darnelldibbles)

    Hi there,

    The tracks script is more than tracking visitor stats, but it enables the tracking tools we use for your site (cookies) For more information, you can read up on all that we track:

    https://automattic.com/cookies/

    what is the proper way to prevent this script from loading?

    To deactivate the Tracks scripts on the admin pages, you can toggle the setting on this page:
    https://kabultec.org/wp-admin/admin.php?page=jetpack#/privacy

    To increase speed in general, I would deactivate any Jetpack modules you are not using or are not planning on using:

    https://kabultec.org/wp-admin/admin.php?page=jetpack_modules

    For more information on the modules, please visit:

    https://jetpack.com/support/control-jetpacks-modules-on-one-page/

    You have site accelerator and lazy loading enabled, so that is helping.

    Here are some more ideas on how to speed up your site:

    https://jetpack.com/2018/08/14/improve-wordpress-site-speed/

    Hope this helps!

    Thread Starter cag8f

    (@cag8f)

    OK thanks for your help so far. We are making progress, but I am still unclear about a few things, if you don’t mind.

    >> The tracks script is more than tracking visitor stats, but it enables the tracking tools we use for your site (cookies) For more information, you can read up on all that we track: https://automattic.com/cookies/

    I read that page. It indicates there are several types of cookies. The “Strictly Necessary” cookies are, “…essential for websites on our services to perform their basic functions.” If I deactivate the Tracks script as per your instructions, will that disable *all* cookies, even the “Strictly Necessary” cookies?

    >> To deactivate the Tracks scripts on the admin pages, you can toggle the setting on this page:

    OK I opened that page. But I don’t see which setting you’re referencing. Can you clarify? Here is what I see.

    Thanks.

    Plugin Support darnelldibbles

    (@darnelldibbles)

    Hi there,

    OK I opened that page. But I don’t see which setting you’re referencing. Can you clarify? Here is what I see.

    Hmm..that isn’t what you should see. From the wp-admin, go to Jetpack > Settings. Scroll all the way down to the bottom, and there is a link that says Privacy. Click on that link and you should see this:

    Screen Shot

    Under privacy settings, toggle off Share information with our analytics tool about your use of services while logged in to your WordPress.com account..

    If I deactivate the Tracks script as per your instructions, will that disable *all* cookies, even the “Strictly Necessary” cookies?

    I provided a general cookies page. But, particularly, when opting out of the tracking script, you’ll be only opting out of the functions of the analytic tools that are described here:

    https://jetpack.com/support/privacy/#analytics

    Here is information on Jetpack and cookies:

    https://jetpack.com/support/cookies/

    Hope this helps. Let me know if you have any other questions. Thanks!

    Thread Starter cag8f

    (@cag8f)

    >> Under privacy settings, toggle off Share information with our analytics tool about your use of services while logged in to your WordPress.com account..

    OK I was able to do did that. But the same JS file is being loaded by Jetpack on my page. Thoughts?

    I have cleared all caches.

    • This reply was modified 5 years, 11 months ago by cag8f.
    Plugin Contributor James Huff

    (@macmanx)

    The script is what tracks your stats.

    If you want to remove it entirely from your site’s pages, you will need to disable the stats module by switching off the Stats module from the All Modules view: https://jetpack.com/support/control-jetpacks-modules-on-one-page/

    Thread Starter cag8f

    (@cag8f)

    @macmanx OK I see that page, and deactivated the Site Stats module (screenshot). But when I refresh my page, a file from stats.wp.com is still loaded. I have cleared all caches.

    Thoughts?

    Hi @cag8f,

    I’ve checked your site and the stats module has been successfully deactivated. Can you try purging your site cache and see whether stats.wp.com is still listed afterwards?

    Thread Starter cag8f

    (@cag8f)

    >> I’ve checked your site and the stats module has been successfully deactivated.

    OK. But to be clear, are you saying the JS file no longer loads on my page when you visit it? Are you able to send a screenshot?

    >> Can you try purging your site cache and see whether stats.wp.com is still listed afterwards?

    I’ve purged my page cache, and cleared my browser cache, but I’m still seeing the file loaded (screenshot).

    Thoughts on that? My web host does not implement any server side caching.

    Hi @cag8f,

    I’ve looked into this further and think I have an explanation for what is happening. The stats.wp.com script is part of Jetpack and not exclusively tied to Site Stats. It will run if Jetpack is enabled and active on a site — even if site stats are not enabled.

    But to be clear, are you saying the JS file no longer loads on my page when you visit it?

    Now you’ve sent a screenshot, I can see we were looking in different places ?? I viewed the page source and saw no mention of stats.wp.com listed there (and still don’t).

    Thread Starter cag8f

    (@cag8f)

    Sorry, I’m just getting around to re-visiting this.

    >> I viewed the page source and saw no mention of stats.wp.com listed there (and still don’t).

    I can confirm that on page load, I no longer see any file from stats.wp.com loaded. So I guess deactivating the Site Stats module did the trick. Thanks for the help.

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘JS file from stats.wp.com’ is closed to new replies.