Начало
Календари
Время года
Показывает текущее число,месяц,дату.
JavaScript Calendars: Время года
<!-- ONE STEP TO INSTALL SEASON: 1. Copy the coding into the BODY of your HTML document --> <!-- STEP ONE: Paste this code into the BODY of your HTML document --> <BODY> <SCRIPT LANGUAGE="JavaScript"> <! > <! > <!-- Begin var now = new Date(); var month = now.getMonth() + 1; var date = now.getDate(); var year = now.getYear(); var season; if (month > 1 && month <= 3) season = "Winter"; if (month == 3 && date > 19) season = "Spring"; if (month > 3 && month <= 6) season = "Spring"; if (month == 6 && date > 20) season = "Summer"; if (month > 6 && month <= 9) season = "Summer"; if (month == 9 && date > 21) season = "Fall"; if (month > 9 && month <= 12) season = "Fall"; if (month == 12 && date > 20) season = "Winter"; //Y2K Fix if (year < 2000) year = year + 1900; //Winter Season Fix if (season == "Winter") year = year - 1; document.write(season + " " + year); // End --> </script> <!-- Script Size: 1.24 KB -->