Skip to content

Instantly share code, notes, and snippets.

@JohnRDOrazio
Last active September 8, 2023 03:45
Show Gist options
  • Save JohnRDOrazio/983f5bc715ba81b8e624cbf200e6f1b8 to your computer and use it in GitHub Desktop.
Save JohnRDOrazio/983f5bc715ba81b8e624cbf200e6f1b8 to your computer and use it in GitHub Desktop.
let liturgyToday = {};
$.getJSON('https://www.johnromanodorazio.com/LiturgicalCalendar/LitCalEngine.php?diocesanpreset=DIOCESIDIROMA',function(data){
for(const [key,entry] of Object.entries(data.LitCal)){
let entryDate = new Date(entry.date * 1000);
if(entryDate.getUTCMonth() == new Date().getMonth() && entryDate.getUTCDate() == new Date().getDate()){
liturgyToday[key] = entry;
}
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment