• Resolved Saumya

    (@saumya010)


    I have been using this plugin for some time in form of widgets and shortcodes and recently it has started displaying posts from 2020 for the timeframe last 30 days, 7 days and even 24 hours.
    I have double-checked that there were no views for those 2020 report(s) in Google Analytics but still not sure why older reports are displayed?

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Hector Cabrera

    (@hcabrera)

    Hi @saumya010,

    By default the shortcode lists all popular posts regardless of their publication date. It’s always been that way and you likely only noticed that behavior just now.

    If you want the shortcode to only list popular posts that have been published within the specified time range (eg. last 30 days) then make sure to use the freshness parameter with your shortcode, see Parameters for more details.

    Plugin Author Hector Cabrera

    (@hcabrera)

    As to why some post / page views are not showing on Google Analytics, honestly no idea. Here’s a good (and long) read about the matter: Popular Posts views count different than Jetpack’s? (applies to GA as well, the thread being about Jetpack isn’t relevant).

    Thread Starter Saumya

    (@saumya010)

    Thanks for the prompt reply Hector. Here is the shortcode that I am using to display posts from the last 24 hours sorted by the number of views.

    [wpp range=”last24hours” limit=10 stats_views=1 order_by=”views” stats_date=1]

    So, technically it should display the posts which are viewed the most in the last 24 hours. However, it is displaying some posts from 2020 which does not make sense as the latest published posts have more chances of higher views.
    I also understand your point of using the “freshness” parameter, but that will limit to the posts published within the last 24 hours as opposed to the most viewed posts in that time frame.
    Hope you understand the issue here and provide a suggestion based on that along with the shortcode I referred to.
    Thanks

    Plugin Author Hector Cabrera

    (@hcabrera)

    There’s no issue IMO, it’s just how popular lists work in general: as long as a post appears on your popular posts list visitors will click on it, and the more people click on it the longer the post will stay on your list until another post takes its place.

    Thread Starter Saumya

    (@saumya010)

    From a technical standpoint, I agree with you. But again based on prior data, a particular post from 2020, which is not relevant today and still shows a high number of views does not make sense.
    If you know any other way to troubleshoot this and make sure that the page count is indeed correct, kindly let me know.

    Plugin Author Hector Cabrera

    (@hcabrera)

    If a post appears under your popular posts list it means that it’s been visited, its views data has been stored on your database. As long as it has enough views within the selected time range (eg. last 30 days) it might show up on your popular posts list.

    Also, keep in mind that people also find your website via search engine results (unless you for some reason have blocked search engines via robots.txt or some other mean) and not only via direct browsing (as in typing your site’s URL in the address bar) so it’s not crazy for an older article to rank better than most recent ones, especially if the older post contains the right keywords / key-phrases for a particular topic and that it has been getting good search result rankings over time.

    As you said yourself, from the technical standpoint the plugin is working as expected.

    If you want your newer posts to rank better than your popular ones then:

    • promote the newer ones more so they get more traffic than your older ones (share them on social media, with friends, etc),
    • make sure that your articles are SEO friendly (as in they’re using the right keywords / key-phrases, the page itself is using the right HTML tags, etc)
    • make sure that the contents themselves are interesting enough for them to actually outrank older popular posts.
    Thread Starter Saumya

    (@saumya010)

    Thanks, I will keep an eye on such anomalies from now on to verify if the views are correct or not.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Incorrect results in widget/shortcode’ is closed to new replies.