Hello,
I am using Newspaper 8.5.1 on WordPress 4.9.1 and i have a News Ticker on my homepage to show some chosen posts. The problem is that if i use the ‘Popular ( last 7 days ) ‘sort filter, the chosen posts are not from the last 7 days but years old.
With the ‘Random posts from last 7 days’ filter, everything works correctly but i needed the former filter. Now, at the moment there are no caching plugins active on the site ( there used to be ), and from the panel both the option ‘Post Setting > Enable/Disable post view count’ and ‘Block Settings > Use 7 days post sorting’ are active .
I’d like to know how to achieve the desired filter ,thanks.
Hi,
Maybe you have caching active? The 7 days popular sorting will not work with a caching plugin as mentioned in the guide
– https://forum.tagdiv.com/7-days-post-sorting/
So if you use caching the 7 days will not work for any block, grid etc not only the news ticker. Sorry for the inconvenience.
I tested it with no caching, the ticker displays the posts with most views from a 7 days period of time, from the categories you choose.
Thanks
Somehow I missed that, indeed if the random posts from 7 days works and only displays posts that qualify, then the other popular 7 days should work.
Please check if the post views are counted properly, open a post page and refresh the page a few times, check if the count goes up.
Caching may still affect these sorting methods if you use it, that is why they are declared incompatible with caching. It may work partially or not at all.
I tried to check if on the database the numbers are updated ;
On my database, every post has these meta keys :
post_views_count
post_views_count_7_day_arr
post_view_7days_last_day
post_views_count_7_day_last_date
post_views_count_7_day_total
post_views_count and post_views_count_7_day_total and the array updated as expected ; while the other 2 values didn’t.
I believe each post will have it’s view count saved in the database
– https://www.screencast.com/t/8hn0tv4kWX1
As the post get views they will be stored there, if the 7 days option is active and working it should increase the value for the post as well. In my test it does.