in reply to Re^2: DateTime and hour 0
in thread DateTime and hour 0

Zero-padding is best done with printf or sprintf. I don't know where num_to_month is coming from (something you wrote?) but why not just use $datetime->month_name?