Example

The below source code changes the background color of a page depending on the color of the day. As you can see in this example, the page will be a different color reflecting the time of day. This code should be placed in thetags of HTML your code.

Source code

  • See our JavaScript definition for further information and related links on this term.