Skip to:

Opened 14 years ago

Closed 14 years ago

#2238 closed defect (bug) (duplicate)

"sent X time ago" discrepancy in Sent Messages

Reported by: 3sixty's profile 3sixty Owned by:
Milestone: 1.5 Priority: major
Severity: Version:
Component: Activity Keywords: time zone, time, messages


DJPaul suggested posting this as a bug report. I can't get Messages to report "time ago" correctly without breaking the time reporting in the Forums. Out of the box, Forums are reporting times correctly ("Posted 2 seconds ago") but Messages report incorrectly ("Posted 5 hours ago"). In an attempt to fix this, I tried using date_default_timezone_set(); which fixed Messages, but it "broke" Forums - the times now say "Posted sometime ago".

I Ensured my WP install is set to use the same timezone as my server, but this seemed to have no effect.

In debugging, I sent a test Message that had a Sent Time of 2010-03-24 08:22:03 when UTC time is 2010-03-24 13:22:52 (5 hour difference).

Change History (3)

#1 @3sixty
14 years ago

PS. I was able to replicate this on a test install of BP on my own server, but not at

#2 @3sixty
14 years ago

I made some headway.

This my BP installation is on shared hosting, so the server time zone is different than the WP installation timezone. However, BP Messages is using the *server* time when it INSERTs the message record (bp-messages-classes.php). I detailed some more of the fix here:

#3 @cnorris23
14 years ago

  • Resolution set to duplicate
  • Status changed from new to closed

See #2203

Note: See TracTickets for help on using tickets.