html basix - html tutorial for the beginner. Html code generators including colored scrollbar, colored link mouseover, meta tag generator, list generator,forms generator, email form generator, popup window generator, tables generator, javascript banner rotator generator, link status hider, form styles generator, bookmark page generator, set homepage code generator, javascript alert generator, htaccess images generator, frames generator and mouse trails generator.




Htaccess code generators Code generators Tutorials
Google
Web
HTML Basix


Free Websites
Html Tools
Free Clipart
Tell a Friend Scripts

Online and offline code generators



HTMLBasix fully recommends Hostmonster as your host of choice.
Masses of space, transfer (yes, that's 15 TB!!!), great uptime. All for a VERY affordable price!
Introduction  1  2  3  4  5  6  7  8  9  10  Home


Lesson 7 - Backgrounds

How to use a solid colour as a background.

To make the background of your webpage a colour other than the basic white it is now, you need to ADD it in the <body> tag (which you have already typed). The command you use is 'bgcolor', and it's written like this:

<body bgcolor="#000000">. Choose whatever colour you like for a background using the colour chart. What more can I say?


Using an image as a background...

If you want to use a picture as the background to your page, you need to use either a .gif or .jpg file. You can use a .bmp, but these are usually a lot bigger in 'size' than the .jpg or .gif. As such, your page will take a long time to load when someone visits it.



We are going to use the picture above. Right click on it, and 'save image as...''. Save it in the folder where your html file is, and make sure it's saved as clover.gif.

In your body tag, instead of typing in 'bgcolor="#000000", type in 'background="clover.gif"'. The way it looks in the tag is:
"<body background="clover.gif">".

Of course, you could keep both background colour AND background image:
"<body bgcolor="#000000" background="clover.gif">"

Save your notepad page, then refresh your html page. You will notice that whereas the picture you downloaded is a small square, when you set it as a background it 'tiles', or repeats itself until the page is full. Because of this, make sure the picture you choose as a background will look ok tiled!

To see what the background looks like, click here.

For an example of a background image that doesn't tile well....check this out!

Backgrounds done, now you can learn how to put a picture on your page in lesson 8!


Introduction  1  2  3  4  5  6  7  8  9  10  Home




Site Stats     
VisitorsPageviews
Total: 4,463,034 Total: 13,256,313
Today: 182 Today: 549
Yesterday: 2,764 Yesterday: 8,915
Past Month: 85,684 Past Month: 276,365

2,767 visitors in the last 24 hours
This page has been visited 28,520 times
There are currently 23 visitors online
click to see where
most people online at once:
77 visitors on 04/05/2007
   You beaut











This site is © HTML Basix 2003 - 2006