title: Convert PHP date to Excel?
body: <p>Excel's date format is, I believe, the # of days since December 30, 1899. (Why? Because it's based on 1/1/1900 but they erroneously include a leap day in 1900, and it's one-based. So it's fine for the first couple of months in 1900 but then it goes wrong. 1/1/1901 in Excel is "367".)</p>
  
  <p>So, how can I convert a date or timestamp from PHP (which is typically stored as a Unix timestamp, the # of seconds since 1/1/1970) to Excel? </p>
  
  <p><em>In PHP 5.1.6?</em></p>
  
  <p>Yeah, bet you didn't see that one coming. So I don't have any of the DateTime objects, date_create(), date_diff(), etc. functions available to me.</p>
  
  <p>Is it even possible without simply recording the Excel day for 1/1/1970 and working from there? And is there a DST-proof version?</p>