$month and $year are read from an external file.
No date is read from the external file.
$daysInMonth simply wants to get how many days in a month.
$date just want to echo back the month & year as follows:
$date = mktime(0, 0, 0, $month, $day, $year);
echo date("F Y", $date);