|
In addition to using simple colors for backgrounds, you can use images as backgrounds. To do so, you specify a URL pointing to an image for the BACKGROUND attribute of the <BODY> tag. You can specify a relative URL or an absolute URL: - A relative URL points to a file located in or below the same directory as the Web page.
- An absolute URL points to a file located anywhere on your computer.
Let's say you had a star graphic that you've uploaded to your Web page directory that you wanted to use as the background (and you've named the graphic star.gif. Here's the code you'd use to specify that image for the background: <BODY BACKGROUND="star.gif">
Don't forget that in your code, like any element, you'll eventually need to close the body tag. Background images that don't fill the entire background are tiled to cover all available space -- that is, copies of the image are automatically placed together, like a tile floor. If you choose a background image that's a star, for example, there is really only one star, but the browser makes the copies automatically.
|