Login | Sign up | Toll-Free: 1-800-752-0455
 
 

Forum

 

7 posts by 6 authors in: Forums > Off Topic / Other
Last Post: October 16, 2011

Re: [chris] Facebook-style relative times (e.g. "7 hours ago")

By Rusty - January 6, 2011 - edited: January 6, 2011

Ack!! Thanks, that's awesome! Very useful for Blog posts.

I love IF statements!

*saves*
Rusty

Re: [chris] Facebook-style relative times (e.g. "7 hours ago")

Thanks Chris!

Please, more little tips and techniques like this would be great!
Cheers,

Tim Forrest
Toledoh Enterprises
www.toledoh.com.au

Re: [Chris] Facebook-style relative times (e.g. "7 hours ago")

By Toledoh - February 6, 2011 - edited: February 6, 2011

I think it's meant to be
USAGE:
<?php echo pretty_relative_time($record['createdDate']); ?>


"pretty_relative_time" not "pretty_relative_date"
Cheers,

Tim Forrest
Toledoh Enterprises
www.toledoh.com.au

Re: [Toledoh] Facebook-style relative times (e.g. "7 hours ago")

Hi Tim,

Thanks for noting and pointing that out.

I have updated Chris's code example above with the correct function name.
---------------------------------------------------
Cheers,
Damon Edis
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

Re: [Chris] Facebook-style relative times (e.g. "7 hours ago")

This is awesome dude.Can you post more useful code.This is really cool.

Re: [Chris] Facebook-style relative times (e.g. "7 hours ago")

[:)] Thanks for the added info. Very helpful indeed. Gonna look forward for another tips. [:P]