Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 PST on 31 March 2024, to get $100 off your ticket.
By bdparker on
Hi! I'd like to make my Content: Post Date field display how long ago something was posted in addition to the actual post date. Can I do this in Drupal?
I have a Field View which displays Content: Post Date. I wrote my own PHP so that
D, M jS, Y \a\t h:i a
turns in to
Wed, Mar 1st, 2017 at 10:31 am
and I also have it set so that it displays "2 hours 44 seconds ago" if it was posted today.
What I'd like it to do is say "Wed, Mar 1st, 2017 [2 hours ago]" with the date, time ago, and without the seconds display. Is there a way to do that?
Thanks!
Comments
See
https://www.drupal.org/project/timeago