This thread is resolved. Here is a description of the problem and solution.
Problem:
Filter posts by date (default post date)
Solution:
If you want to display exactly 7 days old posts and would like to compare the post date you need to use the view's filter hook: wpv_filter_query
I want to show all post published in last eight days. I tried several combinations but none of them show the results in the right way.
I tried select posts with published date is after or equal day past_one 8. I tried other several combinations.
Also between day current one and day past_one 7.
Hello. Thank you for contacting the Toolset support.
Well - if you want to display exactly 7 days old posts and would like to compare the post date you need to use the view's filter hook: wpv_filter_query
It's not working. The view is 1366. I'll we add later aldo view 1368 (2 views), but with this one is listing a lot of days, (not last seven days (from 9 may - 2 may).
Well - can you please share problem URL where you added the view and access details.
*** Please make a FULL BACKUP of your database and website.***
I would also eventually need to request temporary access (WP-Admin and FTP) to your site. Preferably to a test site where the problem has been replicated if possible in order to be of better help and check if some configurations might need to be changed.
I have set the next reply to private which means only you and I have access to it.
Hi again Minesh. I think that's all works fine. The query in the view had filters with date. I deleted that filters and now the query with your code works perfect!
Thanks a lot for your help.
However i have a question. If I need to query with date filters... Must I do it with functions? Or can I do it with the filters of the view?
Well - its really hard to answer because it totally depends on your requirement. But we have more accurate control for filters which should be applied to default post date using the wpv_query_filter hook.