in reply to timelocal brain freeze

The second day of the month is 2. If you it matters that the one zero is there before the two, one could always use
$mday = sprintf("%02d",$mday);

-enlil