Contact
Web Development Team

resources

helpful hints - CSS



Helpful Hints Cascading Style Sheets (CSS) were first introduced in 1995 to address the problem of saturating HTML code with presentation markup. CSS allows for a much richer presentation of web pages in a more easily managed manner.

Separating document content (written in HTML) from document presentation (font style, size, color, etc.) can improve content accessibility, provide more flexibility and control in the specification of presentation characteristics, and reduce complexity and repetition in the structural content.

Below we offer a few hints on using CSS within your design.



Positioning Div within Monitor Centered Div

If we set relative positioning on div Container, any elements within the container will be positioned relative to div Container. Then if we set absolute positioning on div Something, we can move it to the desired location of div Container using properties 'top' and 'left'.

#container {
   position:relative;
   margin: 0 auto; /* align for good browsers */
   text-align: left; /* counter the body center */
   width: 780px;
   height: 320px;
}
#something {
   position:absolute;
   width: 240px;
   top: 140px;
   left: 100px;
}
Copyright © 2008 by DSD Web Works - All rights reserved.
Site Map