• Resolved ukutabs

    (@ukutabs)


    Hi,

    At the moment I have one list with daily most viewed and one list with most viewed all time using the provided manual install code.

    Is it possible to have multiple instances of custom periods? I would like to add weekly most viewed and monthly most viewed (and thus don’t want to choose).

    Any help is appreciated, thank you!

    Kind regards,
    Jonas.

Viewing 14 replies - 1 through 14 (of 14 total)
  • Plugin Author Ajay

    (@ajay)

    Yes, you can pass an extra parameter daily_range that can be set to 7 and 30 respectively

    Refer to the full list of parameters: https://webberzone.com/support/knowledgebase/top-10-shortcodes/

    Thread Starter ukutabs

    (@ukutabs)

    Hi Ajay,

    Thank you for your quick response! I’ve tried that before, but it seems to default to the most viewed posts without limit.

    Confirmed when using:

    echo do_shortcode( '[tptn_list limit=99 daily_range=1]' );

    That it doesn’t return the same list as the daily most viewed posts, but it returns the same list as the most viewed posts of all time.

    Does it need an additional argument passed through to tell it to use a custom range?

    Thank you!

    Plugin Author Ajay

    (@ajay)

    
    echo do_shortcode( '[tptn_list limit=99 daily_range=1 daily=1]' );
    

    How about this?

    Thread Starter ukutabs

    (@ukutabs)

    Hi Ajay,

    That indeed now displays the same list as the daily most viewed list. However:

    1. It ignores the limit=99 argument and even when left out it still defaults to 10 posts. Although in the settings in the dashboard it’s also set to 99.

    2. When using it then for daily_range=7 or daily_range=30 days most viewed posts, it’s showing the same list as the daily most viewed posts now (instead of the same list as overall most viewed posts before).

    Any clue?

    Kind regards,
    Jonas.

    Plugin Author Ajay

    (@ajay)

    I will run some tests as well. Can you check if caching is off.

    Are the full shortcodes that you are using? And does it work with putting the values into double quotes?

    So limit=”99″

    Thread Starter ukutabs

    (@ukutabs)

    Hi Ajay,

    Didn’t made the link with caching and list generation. It was activated and time to cache set to 7200 seconds.

    The moment that I turned it off, it generated four different lists (daily / 7 days / 30 days / overall). The main issue, and the reason why caching must be on, is that the load is unmanageable with caching off and it crashes the server.

    So I was able to watch the four lists for a few seconds and then the server crashed. Turning caching back on, resulted in the same lists again and defaulting to 10 posts.

    Thank you for your help!

    Kind regards,
    Jonas.

    Plugin Author Ajay

    (@ajay)

    Jonas,

    Thanks for the feedback. I never expected caching the shortcodes separately. The widgets are cached by widget.

    I suspect you have a significant page views which is creating this issue.

    I will need to rebook at my caching code and prioritise this for version 3.0.0 but it is a few weeks away at minimum.

    Thread Starter ukutabs

    (@ukutabs)

    Hi Ajay,

    OK, no problem! I can wait a few weeks. The daily and overall are fine for now, loving the plugin and looking forward to the update!

    (FYI On a typical day there are around 6 million pageviews. The overall most viewed posts page is by far the most viewed page. That’s why I’m looking into expanding it to 7 and 30 day period lists :-).)

    Take care!
    – Jonas.

    Plugin Author Ajay

    (@ajay)

    Wow! I’m super glad to hear that the plugin can handle those views. Explains the need for the cache without a doubt.

    I’ll let you know when I can get a working beta for 3.0.0 with the shortcode caching enabled, if you’re interested in trialling it.

    Plugin Author Ajay

    (@ajay)

    @ukutabs

    Just wanted to update that I have this implementated in the Github repo. I will look to push this out over the course of this week.

    Thread Starter ukutabs

    (@ukutabs)

    Wow Ajay, that’s truly wonderful! I’m very grateful, looking forward to the update.

    Plugin Author Ajay

    (@ajay)

    @ukutabs

    I forgot to respond, but I released an updated plugin that includes the shortcode caching amongst other features

    Thread Starter ukutabs

    (@ukutabs)

    Hi Ajay!

    I did see the update in the dashboard and updated immediately, much appreciated! Is there any box to enable this, or is it enabled by default?

    – caching is on
    – time to cache 1800

    I’m using this for the four lists:

    – daily
    tptn_show_daily_pop_posts();

    – weekly
    [tptn_list limit="99" daily_range="7" daily="1"]

    – monthly
    [tptn_list limit="99" daily_range="30" daily="1"]

    – all time
    tptn_show_pop_posts();

    Daily, weekly and all time are different. However, monthly outputs the exact same list of 99 posts like the daily one :-). No idea what’s going wrong.

    Updated the settings several time to try to refresh it, now it’s untouched for several days, but still the same.

    Already glad that the weekly list is different :-).

    Thank you, once again!
    – Jonas.

    • This reply was modified 4 years, 6 months ago by ukutabs.
    Plugin Author Ajay

    (@ajay)

    Can you navigate to Tools and then delete the cache there – might help to disable and renable the Cache setting.

    Only thing I can think of is if you have another caching plugin that has more persistent caching that’s preventing from being updated?

    Do the above settings work when you temporarily disable the cache?

Viewing 14 replies - 1 through 14 (of 14 total)
  • The topic ‘Multiple custom period lists?’ is closed to new replies.