Scripts.FranciscoCharrua.com
HotScripts.com - Over 10 web rings.
more links...
user name
password
don't keep me logged
keep me logged for a month
keep me logged for 6 months
keep me logged for a year
Index
News
Samples
E-Mail me
Forums
Sign Up
CALENDAR.JS
calendar() displays a calendar page of the chosen month and year. The function takes a date object as its only parameter. If this one is omitted, the calendar will default to the date on the client computer.
see also :
calendar.js
,
php-calendar.php
,
asp-calendar.asp
agenda-calendar.php
,
agenda-calendar.asp
server-side-clock.php
,
server-side-clock.asp
next-week.php
,
next-week.asp
,
javascript-next-week.js
server-side-countdown-clock.php
,
server-side-countdown-clock.asp
countdown-clock.js
function calendar(date) { //If no parameter is passed use the current date. if(date == null) date = new Date(); day = date.getDate(); month = date.getMonth(); year = date.getFullYear(); months = new Array('January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'); this_month = new Date(year, month, 1); next_month = new Date(year, month + 1, 1); //Find out when this month starts and ends. first_week_day = this_month.getDay(); days_in_this_month = Math.round((next_month.getTime() - this_month.getTime()) / (1000 * 60 * 60 * 24)); calendar_html = '
'; calendar_html += '
' + months[month] + ' ' + year + '
'; calendar_html += '
'; //Fill the first week of the month with the appropriate number of blanks. for(week_day = 0; week_day < first_week_day; week_day++) { calendar_html += '
'; } week_day = first_week_day; for(day_counter = 1; day_counter <= days_in_this_month; day_counter++) { week_day %= 7; if(week_day == 0) calendar_html += '
'; //Do something different for the current day. if(day == day_counter) calendar_html += '
' + day_counter + '
'; else calendar_html += '
' + day_counter + '
'; week_day++; } calendar_html += '
'; calendar_html += '
'; //Display the calendar. document.write(calendar_html); }
hosting with cpanel
best hosting
premium website host