Tag Info

New answers tagged


Yes, you can do that using PHP. Here's a function from @arnorhs: $time = strtotime('2010-04-28 17:25:43'); echo 'event happened '.humanTiming($time).' ago'; function humanTiming ($time) { $time = time() - $time; // to get the time since that moment $time = ($time<1)? 1 : $time; $tokens = array ( 31536000 => 'year', ...


There are a few options, none of which really work great. This is a WordPress bug, and it genuinely sucks because the time is wrong unless you set your site to UTC... which is confusing and not always even possible. This next code I think only works if you choose your Timezone (Under Settings -> General in admin) as a named city instead of by an GMT number ...

Top 50 recent answers are included