Thursday 08th of January 2009 12:37:00 PM

Nice and Free CSS Templates

count on a particular behavior, which makes the utility of negativemargins on floats rather limited. Hanging floats are probably fairlysafe, but trying to push an element upward on the page is generally abad idea.

There is one other case where a floated element can run outside ofits parent element, and that's when the floated element iswider than its parent. In that case, the floated element will simplyoverrun either the right or left inner edge in its best attempt todisplay itself correctly, depending on which way it was floated. In

This site contains free css templates for your website - Just copy and paste and there you have a stunning website !

Menu und content
dynamic

Menu fixed, content
dynamic

Menu und content
dynamic

3 columns all
dynamic

4 columns all
dynamic

Menu floating

Menu fix, Inhalt u.
Head dynamic

3 columns fix
centered

dynamic mit
Head und Footer

fixed BOX centered

dynamic BOX
centered

fixed Box total
centered
it's very simple. This declaration would be displayed as shown in Figure 7-49:

The drawback with border is that you can only define "global" styles, widths, and colors. In other words, the values you supply for border will apply to all four sides equally. If you want the borders to be different for a single element, you'll need to use some of the other border properties. Of course, it's possible to turn the cascade to your advantage: to substitute a similar font.

Example

font-sizeIE4 P/Q IE5 P/Y NN4 Y/Y Op3 Y/-

This sets the size of the font. Thiscan be defined as an absolute size, a relative size, a length value,or a percentage value. Negative length and percentage values are notpermitted. The dangers of font-size assignment are many and varied.Some of these dangers are covered in Chapter 4, "Text Properties".

Example

Figure 8-6

Figure 8-6. Horizontal margins don't collapse

Almost as simple is this: the sum of the horizontal components of anonfloated block-level element box always equals thewidth of the parent. Take two paragraphswithin a DIV, for example, whose margins have beenset to be 1em. The content width (in other words,the value of width) of the paragraph, plus itsleft and right padding, borders, and margins, always add up to thewidth of the DIV 's

Figure 7-55

Figure 7-55. An inline element with a border displayed across multiple lines of text, with the border boxes closed

It's also acceptable for the lines to be "open" as shown in Figure 7-54.

WARNING

Borders cannot be applied to inline elements in Navigator 4.x or Explorer 4.x/5.x. Only Opera 3.x draws borders around inline elements, and it only caps the beginning and end of the it (usually) with selectors that list various table elements. For example, in order to get all your table content to be red along with your document's body, try this:

BODY, TABLE, TD, TH {color: red;}

This will often solve the problem. I say "often" because it doesn't always work, for reasons that are poorly understood. Navigator 4 has the most trouble getting it right, but its failures are not consistent. The best minds in CSS analysis have yet to come up with a recipe for predicting Navigator's behavior,