A timestamp is the time at which an event is recorded by a computer system. The timestamp term may also refer to Unix Time or to the timestamp data type.

165
votes
28answers
172k views

Converting timestamp to time ago in PHP e.g 1 day ago, 2 days ago…

I am trying to convert a timestamp of the format 2009-09-12 20:57:19 and turn it into something like 3 minutes ago with PHP.I found a useful script to do this, but I think it's looking for a ...
2147
votes
32answers
663k views

Should I use the datetime or timestamp data type in MySQL?

Would you recommend using a datetime or a timestamp field, and why (using MySQL)? I'm working with PHP on the server side.
753
votes
22answers
855k views

Convert a Unix timestamp to time in JavaScript

I am storing time in a MySQL database as a Unix timestamp and that gets sent to some JavaScript code. How would I get just the time out of it?For example, in HH/MM/SS format.
3149
votes
34answers
2.1m views

How do you get a timestamp in JavaScript?

How can I get a timestamp in JavaScript?Something similar to Unix's timestamp, that is, a single number that represents the current time and date. Either as a number or a string.
284
votes
19answers
699k views

How to convert date to timestamp in PHP?

How do I get timestamp from e.g. 22-09-2008?
37
votes
8answers
61k views

Timezone conversion in php

Can anyone suggest an easy method to convert date and time to different timezones in php?
35
votes
3answers
17k views

Convert timestamps with offset to datetime obj using strptime

I am trying to convert time-stamps of the format "2012-07-24T23:14:29-07:00" to datetime objects in python using strptime method. The problem is with the time offset at the end(-07:00). Without the ...
195
votes
8answers
202k views

Java: Date from unix timestamp

I need to convert a unix timestamp to a date object.I tried this:java.util.Date time=new java.util.Date(timeStamp);Timestamp value is: 1280512800The Date should be "2010/07/30 - 22:30:00" (as ...
85
votes
17answers
101k views

PHP How to find the time elapsed since a date time? [duplicate]

How to find the time elapsed since a date time stamp like 2010-04-28 17:25:43, final out put text should be like xx Minutes Ago/xx Days Ago
521
votes
16answers
182k views

How can one change the timestamp of an old commit in Git?

The answers to How to modify existing, unpushed commits? describe a way to amend previous commit messages that haven't yet been pushed upstream. The new messages inherit the timestamps of the ...
45
votes
14answers
196k views

Convert Date/Time for given Timezone - java

I want to convert this GMT time stamp to GMT+13:2011-10-06 03:35:05I have tried about 100 different combinations of DateFormat, TimeZone, Date, GregorianCalendar etc. to try to do this VERY basic ...
26
votes
8answers
17k views

PHP: producing relative date/time from timestamps

I'm basically trying to convert a Unix timestamp (the time() function) to a relative date/time that's both compatible with past and future date. So outputs could be:2 weeks ago1 hour and 60 ...
46
votes
2answers
89k views

Handling MySQL datetimes and timestamps in Java

In a java application what would a good compromise in terms of extracing and inputting date information with a MySQL database using a mix of datetimes and timestamps?
91
votes
8answers
221k views

java convert milliseconds to time format

I am trying to convert a long value (The number of milliseconds elapsed from 1/1/1970) to a time of format h:m:s:msThe long value I use as timestamp, I get from the field timestamp of logging event ...
65
votes
8answers
426k views

How to convert SQL Server's timestamp column to datetime format

As SQL Server returns timestamp like 'Nov 14 2011 03:12:12:947PM', is there some easy way to convert string to date format like 'Y-m-d H:i:s'.So far I use date('Y-m-d H:i:s',strtotime('Nov 14 2011 ...

153050per page
angop.ao, elkhabar.com, noa.al, afghanpaper.com, bbc.com, time.com, cdc.gov, nih.gov, xnxx.com, github.com,