Codes à insérer entre les balises <BODY> et </BODY> de votre document HTML
<script language="JavaScript"> <!-- //Script mis au poinbt par Michael Mailer //URL: http://www.webaid.de/js -- eMail: mm@webaid.de //SVP, ne pas supprimer ce commentaire ! // fill the month table with column headings function day_title(day_name){ document.write("<TD ALIGN=center WIDTH=35>"+day_name+"</TD>") } // fills the month table with numbers function fill_table(month,month_length) { day=1 // begin the new month table document.write("<TABLE BORDER=3 CELLSPACING=3 CELLPADDING=%3><TR>") document.write("<TD COLSPAN=7 ALIGN=center><B>"+month+" "+year+"</B><TR>") // column headings day_title("Di") day_title("Lu") day_title("Ma") day_title("Me") day_title("Je") day_title("Ve") day_title("Sa") // pad cells before first day of month document.write("</TR><TR>") for (var i=1;i<start_day;i++){ document.write("<TD>") } // fill the first week of days for (var i=start_day;i<8;i++){ document.write("<TD ALIGN=center>"+day+"</TD>") day++ } document.write("<TR>") // fill the remaining weeks while (day <= month_length) { for (var i=1;i<=7 && day<=month_length;i++){ document.write("<TD ALIGN=center>"+day+"</TD>") day++ } document.write("</TR><TR>") // the first day of the next month start_day=i } document.write("</TR></TABLE><BR>") } //--> </script><script language="JavaScript"> <!-- //Script mis au point par Michael Mailer //URL: http://www.webaid.de/js -- eMail: mm@webaid.de //SVP ne pas supprimer ces commentaires ! // year year=2001 // first day of the week of the new year today= new Date("January 1, "+year) start_day = today.getDay() + 1 // starts with 0 fill_table("Janvier",31) fill_table("Février",28) fill_table("Mars",31) fill_table("Avril",30) fill_table("Mai",31) fill_table("Juin",30) fill_table("Juillet",31) fill_table("Aout",31) fill_table("Septembre",30) fill_table("Octobre",31) fill_table("Novembre",30) fill_table("Décembre",31) //--> </script> Cliquez ici pour tout sélectionner
Une fois le code copier/coller remplacer "year=2001" par l'année en cours