<P> Lorem ipsum, dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut <SPAN CLASS="change">***</SPAN> laoreet dolore magna aliquam erat volutpat.</P>

While this does rely on inserting an extra element, the advantage is that the SPAN can be placed anywhere in the paragraph and still have the result depicted in Figure 9-21.

Figure 9-21

Figure 9-21. Setting a "change bar" with absolute positioning

However, maybe we'd like to place the change marker next to whatever line was changed. In that case, we need to make only one

Thursday 08th of January 2009 12:30:03 PM

Nice and Free CSS Templates

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
illustrated in
Figure 8-33.

Figure 8-33

Figure 8-33. Unlike balloons, floated elements can't float upward

5. A floating element's top may not be higher thanthe top of any earlier floating or block-level element.

Similar to rule 4, this keeps a floated element from floating all theway to the top of its parent element. Thus, if aDIV 's first child element is a paragraph,followed by a floated image and then another paragraph, the top of

As you can see, this property accepts any length value or apercentage. That's all. So if you want allH1 elements to have 10 pixels of padding on allsides, it's this easy, as the result shown in Figure 7-56 makes clear:

H1 {padding: 10px; background-color: silver;}
Figure 7-56

Figure 7-56. Padding applied to an H1 element

On the other hand, we might want H1 elements tohave uneven padding and H2 elements to have regular padding, as shown effect, as depicted in Figure 7-34:

P.new1 {border-style: solid dashed none;}
P.new2 {border-style: solid dashed none dashed;}
Figure 7-34

Figure 7-34. Equivalent style rules

In case you're wondering, under CSS1, there is no way to directly set the style for only a single side using something like border-top-style, since no such property exists in CSS1 (although that property, and others like it, were introduced in CSS2). You can, however, sneak around this limitation by declaring

Figure 7-74

Figure 7-74. Clear to the left

However, this will allow floated elements to appear on the right sideof H2 elements, as shown in Figure 7-75.

Figure 7-75

Figure 7-75. Clear to the left, but not the right

To avoid this sort of thing, and to make sure thatH2 elements do not coexist on a line with anyfloated elements, we use the value both. Thisvalue prevents coexistence with floated elements on both sides of theelement, as shown in Figure 7-76: