• Resolved bkelleher

    (@bkelleher)


    Hi,

    Beehive plugin appears to work great, it installs a Google Tag Manager script correctly, and the statistics page in the backend is really useful for our clients.

    However, I have noticed that the in-page statistics (that show on the backend of post edit screen) are always 0. Our analytics property has plenty of information on individual posts and pages, and even on the general statistics page (/wp-admin/admin.php?page=beehive-google-analytics#/statistics), it shows stats for individual posts and pages on the site. However, if you navigate to those posts or pages and view the backend of the post, all of the statistics related to that post or page are 0, and remain 0 forever.

    I have tried disabling all plugins and using WordPress 2020 theme, and I still have the same result. This might be a more in-the-weeds question related to this plugin and how data is stored in our analytics property, but I don’t see any difference between individual post/page statistics in Google Analytics property compared to another website that uses beehive and works fine.

    Any ideas on how to debug/proceed, or is this a known issue in Beehive?

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter bkelleher

    (@bkelleher)

    Digging in, I believe this is because my network_site_url() returns the path to my WordPress installation, which in this case, is not the same exact as the root of my WordPress site. For example, my WordPress is installed in https://example.com/subdirectory, and my site is accessible at https://example.com/, so my WP_SITEURL constant is https://example.com/subdirectory, causing this function to return that URL. My Google Analytics do not include /subdirectory in the path so they always return 0 results. Would we consider adding an option to adjust the base URL that is requested for each post or page? Or consider an additional check for the home url compared to WordPress installation url?

    I made an adjustment on my local instance in core/modules/google-analytics/stats/class-request.php line 229-233 to adjust for my WordPress installation URL not matching my home URL and my problem was resolved, but this is a short term patch to test this theory.

    Plugin Support Nithin – WPMU DEV Support

    (@wpmudevsupport11)

    Hi @bkelleher,

    I’m passing your observation and feedback to our Beehive teams attention and will get back to you regarding the status asap.

    Thanks for bringing this to our attention. Really appreciate. Have a nice day ahead.

    Best Regards,
    Nithin

    Joel James

    (@joelcj91)

    Hey @bkelleher,

    Thanks for the report. Yes, instead of network_site_url, we can use network_home_url which should fix the issue. We will update that in next release ??

    Regards,
    Joel

    Thread Starter bkelleher

    (@bkelleher)

    @joelcj91 much appreciated, and thanks for the reply and consideration!

    Plugin Support Patrick – WPMU DEV Support

    (@wpmudevsupport12)

    Hi @bkelleher

    I hope you are doing well.

    We are marking this ticket as resolved, please, keep the plugin updated and the eyes on the changelogs.

    Feel free to reply or re-open if you have any further question.

    Best Regards
    Patrick Freitas

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Individual Post/Page Statistics are 0’ is closed to new replies.