WebworkBackground Color Changes
 
 
 

Using document.bgColor it's possible to change the background color of a page after it has loaded.

Combining document.bgColor with onClick, you can create links that let viewers select their own page background color:

Black Background Gray Background White Background
 
<a href="javascript:;" onclick="document.bgColor='#999999'">Gray Background</a>
 
 
 
 

Combining document.bgColor with onMouseOver, you can create links that are even more fun - though admittedly less useful:

 
<a href="javascript:;" onMouseOver="document.bgColor='#ff00ff'"; onMouseOut="document.bgColor='#ffffff'"><img src="../images/spacer.gif" width="100" height="10" border="0"></a>
 
 
 
 
<Previous | Javascript | Webwork Table of Contents
 
 © Jay Boersma
free stuff
GIFs 4 Us
The Web Rules
Webpix
Backgrounds 4 Us
Webpaper
Digital Sketches 1
Digital Sketches 2
Fonts
Sounds
archive
The Portals Project
Transition
Insights
Spelling
Webwork
photographs
Barcelona, Catalonia/Spain
Along the Mississippi
Rome and Florence
The Reliance Building
Providence, Rhode Island
Santa Fe, New Mexico
Charleston, South Carolina
hell
The Web
Page from
ape silverback
Primate
Ruminations
rotmp
Revenge
of the
Movie
Poster
element-j
Honda
Element
Site