Time of Day Picture Change | JavaScriptSource

Time of Day Picture Change

JavaScriptSource Staff Mar 28, 2008

General

Use this script to change a picture (or banner) depending on the time of the day. Very simple to use!


This picture would display between 7 AM and 5PM
time of day

This picture would display between 5PM and 7 AM
time of day

Notes

Source Code

Paste this source code into the designated areas.

External file

Paste this code into an external JavaScript file named: timePictureChange.js


Head

Paste this code into the HEAD section of your HTML document.


Body

Paste this code into the BODY section of your HTML document


Leave a Response

(10 comments)

You would need to contact to author of script, or hack this one yourself. If you do change this one, we would be glad to add it to our site.

Lee Nov 6, 2008

Well, that would be a different script.

Lee Nov 6, 2008

Your question is beyond the scope of these comments. You will need to post it over on [a href="http://www.webdeveloper.com/forum/forumdisplay.php?f=3"]the JavaScript forum[/a]. Thanks!

Lee Oct 31, 2008

Hey ![br /]This script is real cool ! Works great !![br /](Wish it would support the blend effects...)[br /]We will use it in our Toolbar... MusicPlayer ![br /][br /]Keep up the great work[br /]Mark

Mark Oct 14, 2008

I love the code, can you update it so it makes everyday different as well as every hour?

Marissa Sep 8, 2008