I've seen variations of this before but I keep running into roadblocks that are causing headaches.
What I want to do is change a banner image on my web page by the time of day in my region (Pacific Standard) by using JavaScript. I get the main idea that I have to do for the function, but I'm confused on how I can import an image or add an image into the webpage when it wasn't there before.
function timeOfDayImage() {
var now = new Date;
var timeNow = now.getHours();
if(timeNow < 8 || timeNow > 10){
code
}
else {
code
}
Any help?