PHP Date conversion test

The purpose of this is to test Date conversion functions from the Windows double format to the Unix integer format.

These functions convert from Window time (days since 12-30-1899) to Unix time (seconds since 01-01-1970). This procedure is

The different is 70 years, plus a few leap year days, plus one more day (who knows why?). Because of the data types used, the conversion is only approximate with about 9 seconds of error.

The real problem is that Unix dates fail after 2038! (As shown above where 2040 is shown as 1903!)

There are 2 versions of this page - php and html (for when the PHP version changes - this was developed with version 5.4.3).


Author: Robert Clemenzi
URL: http:// mc-computing.com / Languages / PHP / Date_test.html