CSS WEEK 4: Background Properties


What is the default for background-color?
The default background color is transparent.

True or False? A background-image can only be used for the body of your page.
False. Background images can be used for words, sentences, paragraphs, tables.

Which of the following is the correct syntax for background-image in embedded or linked style?
background-image : url(graphics/wk4bg.jpg);
background-image : url(graphics/wk4bg.jpg)
background-image : url("graphics/wk4bg.jpg");
The correct syntax is, url(graphics/wk4bg.jpg);

True or False? Padding can only be added in equal amounts on each side of your box.

True or False? Border styles are universal in all the major browsers.

True or False? When grouping selectors, it's a good idea to group p, td, etc. with the body selector if using a background-image. Why or why not?
It's not a good idea when the body rule contains a background image. Netscape 4.x doesn't interpret this correctly. Although I'll go out on a limb here and say I'm not sure why Netscape even exists, let alone Netcape 4. I'm in a great mood...can you tell??

More Work With Background Properties

This is an example of using a background image behind words.

Here is an example of equal padding and a width set. As you can see the padding is equal all the way around. Note: I also set my thick border to be dashed.

Here is an example of unequal padding and a width set. As you can see, the padding here is unequal. My border is set to dotted. I didn't care for ridge and groove.

Here I tried a multicolor border.

Email Me.

Valid HTML 4.01!

Valid CSS!