javascript - What is this JSON date in this JSON object? -


i have json analyze

this snippet of necessary question.

"updateddate":"\/date(1311377875937)\/" 

i don't know number is, updated date date item last updated

also, whatever is, how able find out if updated 20 seconds ago or less?

the number datetime, in milliseconds, since 1970. if divide 2 datetimes have 1000 , subtract them should difference in seconds.

var secondsdifference = (new date() - updatedate)/1000; 

Comments

Popular posts from this blog

1111. appearing after print sequence - php -

java - WARN : org.springframework.web.servlet.PageNotFound - No mapping found for HTTP request with URI [/board/] in DispatcherServlet with name 'appServlet' -

Ruby on Rails, ActiveRecord, Postgres, UTF-8 and ASCII-8BIT encodings -