Opened 11 years ago
Closed 7 years ago
#2031 closed enhancement (fixed)
Last post date-time instead of Freshness
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | 2.6 | Priority: | normal |
Severity: | normal | Version: | 2.1 |
Component: | General - Content Creation | Keywords: | has-patch commit |
Cc: | vivek@… |
Description
One feature that I struggle a bit in why bbPress broke from the norm is Freshness. It is customary to have the last column for “Last post” which includes the date-time of last post (topic/reply) and the author of last post.
bbPress has decided to use “Freshness” instead of “Last post” as title. Instead of date-time, it displays time-since.
Perhaps time to move to the more convention approach here. Probably good for performance too - won't need to calculate freshness.
Attachments (6)
Change History (20)
#1
@
11 years ago
Why bbPress should look like others?
"bbPress is plain and simple forum software, plain and simple"
#2
@
11 years ago
- Component changed from Forums to Content Creation
- Milestone Awaiting Review deleted
- Resolution set to wontfix
- Status changed from new to closed
Valid, though easily handled in a theme; there are functions to support this if you want this on your own site.
Closing as wontfix. If it turns into a popular request, we can reopen and revisit this then.
#3
@
9 years ago
- Cc vivek@… added
- Milestone set to Awaiting Review
- Resolution wontfix deleted
- Status changed from closed to reopened
Question is: Why does bbPress go through the extra effort for no benefit? If anything, there's probably a slight performance hit that it takes due to the additional calculation...
bbPress is making an additional calculation, bending over backwards, just to calculate how many seconds, minutes or days have passed since last post.
In this sense, bbPress is breaking from convention that most forum users are familiar with without making performance gains (in fact making performance losses)...as opposed to breaking from convention for performance (or other) gains, which is understandable.
I don’t see the reason and I don’t like it this way. But since it is like this then I must assume that there are other bbPress users who do. Hence…perhaps this should be configurable.
#4
@
9 years ago
- Milestone changed from Awaiting Review to Future Release
There is now a plugin that will do this: http://wordpress.org/plugins/bbp-last-post/
I'll put this in 'Future Release', if a patch comes along we can then add it to an upcoming milestone.
If anyone wants to take a shot at this checkout how it is done currently in bbp_get_topic_post_date
.
#6
@
9 years ago
[Please be nice, I'm an experienced dev but pretty new to Trac. If this conversation belongs in support forums let me know and I'll take it there]
I have to say that I'm a bit confused by this. There seems to be a difference between topic "post date" and topic "freshness".
I'm building a theme where, actually, I want to interleave posts and topics in a display based on their recentness (by which, for topics, I mean "freshness"). So I want to do a comparison (in a usort callback) based on the freshness of the topic - when it was last active.
Options:
- bbp_get_topic_post_date doesn't give me the freshness;
- the plugin is no good because I don't want to affect every display of freshness; and
- bbp_get_topic_last_active_time doesn't give me any choice about how to format the last active date
The only way I can see is to write my own function that looks very much like bbp_get_topic_last_active_time, but that doesn't do the bbp_get_time_since.
I'd really like something like:
function bbp_get_topic_last_active_timestamp( $topic_id = 0 ) { $topic_id = bbp_get_topic_id( $topic_id ); // Try to get the most accurate freshness time possible $last_active = get_post_meta( $topic_id, '_bbp_last_active_time', true ); if ( empty( $last_active ) ) { $reply_id = bbp_get_topic_last_reply_id( $topic_id ); if ( !empty( $reply_id ) ) { $last_active = get_post_field( 'post_date', $reply_id ); } else { $last_active = get_post_field( 'post_date', $topic_id ); } } // Return the time since return apply_filters( 'bbp_get_topic_last_active_timestamp', $last_active, $topic_id ); }
and then bbp_get_topic_last_active() could be:
function bbp_get_topic_last_active_time( $topic_id = 0 ) { $last_active_time = bbp_get_topic_last_active_timestamp( $topic_id ); $last_active = !empty( $last_active_time ) ? bbp_get_time_since( bbp_convert_date( $last_active_time ) ) : ''; // Return the time since return apply_filters( 'bbp_get_topic_last_active', $last_active, $topic_id ); }
Is that reasonable? I'm not up to speed with coding standards but could get that way if you think I needed to just submit a patch?
Does this look like a reasonable thing to do?
#7
@
9 years ago
@magicroundabout This does seem reasonable though it is not specifically what this ticket is requesting, the ticket is about changing the default time/date format bbPress displays topic freshness.
That said, this does belong in Trac, just not this ticket so please create a new ticket and we'll take a closer look.
#8
@
8 years ago
Any thoughts to change "freshness" to "latest posts" or "last post", on next release?
I am translator and many bbpress users complain about "freshness" as bad terminology
#9
@
8 years ago
- Owner set to johnjamesjacoby
- Resolution set to fixed
- Status changed from reopened to closed
In 5867:
#11
@
8 years ago
- Resolution fixed deleted
- Status changed from closed to reopened
There is also need to be changed at https://bbpress.trac.wordpress.org/browser/trunk/src/includes/admin/settings.php#L942
'name' => __( 'Topics by Freshness', 'bbpress' )
to
'name' => __( 'Topics by Date', 'bbpress' )
or something else like by Last activity
#12
@
8 years ago
And another https://bbpress.trac.wordpress.org/browser/branches/2.5/includes/common/widgets.php#L692
'description' => __( 'A list of recent topics, sorted by popularity or freshness.', 'bbpress' )
bbPress