Changing the background on your Web page
Putting a background color on your page
You can put a background color or a background image behind the text on your
web page.
To specify the color you must know the color's hexidecimal number. If you can
find the color's RGB number, you can convert it to hexidecimal using this
handy convertor. There is also a Web page of popular color numbers
to get
you started.
In this example, the color OOFFFF is blue. You must specify the color number in the body tag like this:
<body bgcolor=#OOFFFF>
Click here to see an example of this color in the
background
Putting a background image on your page
You can put a backkgournd image on your page by specifying the image name in
the body tag. The image will be tiled to fit the page. You can get some
ideas for backgrounds by looking at on other pages on the Web or by looking at
collections of images such as Netscape's Background Sampler.
The tag for specifying a background looks like this with the path to the
image. Of course, if you creat your own image and have it in the directory
with the html file, you can just specify the image name.
<body
background="http://home.netscape.com/home/bg/fabric/pink_fabric.gif">
Click here to see an example of this background on the
Webpage
Return to the Advanced HTML tutorial