#739 closed defect (bug) (wontfix)
View by days doesn't work
| Reported by: |
|
Owned by: |
|
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | General | Version: | 1.5 |
| Severity: | major | Keywords: | bg|has-patch |
| Cc: | Technosailor, ciscocable |
Description
When admin sets Options > Reading to view posts last x days, WP displays ALL posts (in my case back to May 19, 2004). Function works as expected when viewing x number of posts.
Attachments (2)
Change History (14)
comment:1
Technosailor — 8 years ago
- Patch set to No
- Summary changed from Reproducible in 1.5b1 nightly build (approx Jan 10) to View by days doesn't work
- Owner changed from anonymous to rboren
- Status changed from new to assigned
comment:5
Technosailor — 8 years ago
Set for 14 days
I know this is an old one ...
If I want to show the last 7 days worth of posts, and set "Show at most:" to 7 days, then what is shown is te last 7 days on which I posted.
This is not how I interpret "Show at most 7 days". I read that as "Show the last 7 days on a rolling basis". So if you come to my blog on 7 September, you will get shown what I posted from 1-7 inclusive and if there is nothing, you see nothing.
Right now, if I have that 7 days and I happen to have posted once a month, you would actually see 7 months worth of posts.
Could we have some way of fixing a rolling period by time, not posts ?
- Milestone set to 2.1
- Owner changed from ryan to westi
- Status changed from assigned to new
Taking this one to see what I can do towards implementing proper "Show at most:" days code
- Keywords bg|has-patch bg|2nd-opinion bg|dev-feedback added
- Status changed from new to assigned
Ok I've worked a patch on this which switches to querying on true days rather than post days.
This also saves us a couple of queries when in this mode per page view as we don't have to work out how to bound ourselves for the "post days"
Known issues:
- If you have no posts recent enough for the first page then it will return as if you queried for nothing
- The Paging code is bust as it currently only works out how many pages to do based on the number of posts in existance which doesn't match well with this query type - see _max_num_pages in template-function-links.php
comment:10
westi — 7 years ago
- Keywords bg|2nd-opinion bg|dev-feedback removed
Ok Ryan, thats fine - I've knocked up and alternate patch which changes the "days" in the dropdown on options >> reading to "days with posts" which makes it explicit that this is how it works.
This should remove any confusion - I too expected it to show "days" rather than "days with posts"
comment:11
westi — 7 years ago
- Resolution set to wontfix
- Status changed from assigned to closed
[4457] Removed "view by days"
comment:12
Nazgul — 6 years ago
- Milestone 2.1 deleted

Curious, works for me. How many days did you set it for?