Metachecker.net
|
TrafficChecker.net
|
RankChecker.net
Learn Java Script Today
|
Over 5000 Free Fonts
|
Tutorials
|
Javascript Forum
|
Other Javascript Resources
|
Cheat Sheet
JavaScript Basics
Inserting Javascript
Complete Tutorial
Advance DHTML Tutorial
Script archive
Advanced Tutorials
Alert Scripts
Animation
Audio
Background Effects
Banner Ads
Browser Window
Buttons
Button Forms
Calculcators
Calendars
Clocks & Dates
Cookies
Cursor Effects
DHMTL Games
DHTML Miscellaneous
Equivalents
Forms
Games
IE4+ Scripts
IE5+ Scripts
Image Effects
Image Miscellaneous
Links & Buttons
Math Related
Messages Miscellaneous
Miscellaneous
Mouse Tricks
Navigation
Page Details
Password Protection
Pulldown Menus
Random Stuff
Scrolling
Status Bar
Text Animation
User Detail
User Info
Window Control
Date Message
Displays your message on the appropriate day you indicate. For example, you can have it print messages on holidays, birthdays, or other dates that are important to you and your site's visitors! Cool!
Insert into <HEAD>
<SCRIPT LANGUAGE="JavaScript"> <!-- This script and many more are available free online at --> <!-- The JavaScript Source!! http://javascript.internet.com --> <!-- Begin var days = new Array(); var msgs = new Array(); days[0] = "December 20, 1999"; msgs[0] = "Thanks for stopping by on my birthday!"; days[1] = "December 21, 1999"; msgs[1] = "Not Christmas yet, it's only the 21st."; days[2] = "December 22, 1999"; msgs[2] = "Another day closer, almost there!"; days[3] = "December 23, 1999"; msgs[3] = "Wow, tomorrow is Christmas Eve!"; days[4] = "December 24, 1999"; msgs[4] = "It's Christmas Eve, thanks for visiting!"; days[5] = "December 25, 1999"; msgs[5] = "Welcome to this page on Christmas Day!"; var months = new Array("", "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December" ); var today = new Date(); // today var mon = months[today.getMonth() + 1]; // month var day = today.getDate(); // day var year = y2k(today.getYear()); // year function dateMsg() { for (i = 0; i < days.length; i++) { tempdate = new Date(days[i]); tempmonth = months[tempdate.getMonth() + 1]; tempday = tempdate.getDate(); tempyear = y2k(tempdate.getYear()); if (year == tempyear && mon == tempmonth && day == tempday) return("Today is " + days[i] + ". " + msgs[i]); // returns day message } return("Today is " + mon + " " + day + ", " + year + "."); // returns default } // Y2K Fix Function function y2k(year) { if (year < 2000) year = year + 1900; return year; } // End --> </script>
Insert into <BODY>
<center> <script> document.write(dateMsg()); </script> </center>
Other Options