Added a function for detecting if the site is within a certain timespan

This commit is contained in:
Bram van der Veen 2015-08-13 22:15:44 +02:00
parent 1c17531016
commit 2bad728b68

View file

@ -21,7 +21,8 @@ function parse(timestr) {
//Function for parsing and checking if the currrent time is within the parsed string.
function within_timespan(timespan) {
if (get() > parse(timespan)[0] && get() < parse(timespan)[1]) return true;
else return false;
}
function during_school() {