in reply to Weird Time: localtime shows wrong month

appearently $month is a part of an array of month names and starts with the index of '0', so add this string before line nomber 8 :  $month++;