elements can appear to be wider than their parents through negative
margins, floated elements can appear to protrude out of their
Let's consider once again a floated image which is floated to
the left, and which has left and top margins of
-15px . This image is placed inside a
DIV which has no padding, borders, or margins. The
result will be as shown in Figure 8-42.
All templates are XHTML 1.0 and CSS2/ tableless.
2 columns / menu and content dynamic
2 column layout grid. The navigation column and content column are dynamic and adjust themselves to the browser window.
This layout also works with an absolute height TEMPLATE 100% height
more nice and free css templates
font-family: Verdana, Arial, SunSans-Regular, Sans-Serif;
margin:0px 0px 50px 0px;
In practice, browsers come with pre-assigned styles for manyelements, and margins are no exception. For example, in CSS-enabledbrowsers, the "blank line" above and below each paragraphelement is generated using margins. Therefore, if you don'tdeclare margins for the P element, the browser mayapply some margins on its own -- which is to say that just becauseyou don't declare margins for an element doesn't meanthat there won't be any.
"blank" space around the paragraphs is actually theirmargins. (If the DIV had any padding, there wouldbe even more blank space, but that wasn't the case here.)
In a similar fashion, the overall width of a list item's element box is equal tothe content width of the list element that contains it. As you cansee in Figure 8-8, the margins of a parent elementcan influence the layout of a child element.
Figure 8-8. List items' overall width equals the width of the UL element
will simply substitute some other font, and the effect you want may bediminished or lost. The <BASEFONT> or <FONT>tags can list multiple fonts in order of preference. The list shouldinclude a generic font family as a last resort, e.g.
<FONT FACE="Creepy, Times New Roman, serif">
Generic font families include serif, sans-serif, monospace,cursiveand fantasy.
Note that as of HTML 4, you are encouraged to use style sheets insteadof these in-line font manipulations, but these tags work fine.