Sibi T Mathew
Sibi T Mathew

Reputation: 93

Ajax auto updation of time and date in social networking site

I am developing a social networking site using php,jquery and ajax. In that i need to update the time and date dynamically, for eg the same way the 'facebook' did this. For each posts or updates, the facebook shows times and date auto updated, like 'few seconds ago','one hour ago', 'two hour ago' etc.. I don't think so, it is sending ajax request for each post for time and date. I am wondering how can i achieve this?. Could anybody explain the implementation logic behind this? Any help, highly appreciated. Thanks.

Upvotes: 1

Views: 209

Answers (1)

Vahid Taghizadeh
Vahid Taghizadeh

Reputation: 997

You can use this plugins for time ago in social networks :

https://github.com/rmm5t/jquery-timeago

http://timeago.yarp.com/

Upvotes: 1

Related Questions