#4340 closed enhancement (fixed)
Outputting timezone-correct timestamp for activity is hard
Reported by: | ericlewis | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 1.6 |
Component: | Activity | Keywords: | |
Cc: |
Description
When displaying the date an activity update was created, bp-default outputs the time elapsed since the activity was created. However, if a theme wants to display that in a timestamp, it will have to do some tricker of its own to print out a properly formatted timestamp that is respective of the timezone set in WP settings.
I think a template function may serve well here, something like get_activity_timestamp(), which would return the timezone-correct timestamp.
Attachments (1)
Change History (8)
#3
@
8 years ago
- Keywords needs-patch good-first-bug added; 2nd-opinion dev-feedback removed
Yes. Root "issue" is we store time/dates in UTC in the database. Not sure best way; could change existing bp_get_activity_date_recorded
but that will break places like in bp-legacy/buddypress/assets/embeds/header-activity.php
.
just a thought.