diff --git a/generate_calendar_dates.php b/generate_calendar_dates.php index e0805d9..a43a6bf 100644 --- a/generate_calendar_dates.php +++ b/generate_calendar_dates.php @@ -6,9 +6,11 @@ /* - Date of the Monday of the first academic week of the year. Teaching weeks start on Monday, so this is a convenient base point to start from. This will need to be updated annually. + Date of the Monday of the first academic week of the year (ISO 8601). Teaching weeks start on Monday, so this is a convenient base point to start from. Note that this is always for the *current* year! */ -$first_monday = new DateTime( "2018-12-31" ); +$first_monday = new DateTime(); +$first_monday->setISODate(date("Y"), 1); + /*