When building a webpage Html framework, try to define class or id only for the outer tag (that is, the parent tag), and the inner tag (that is, the Child tag) if it can be expressed through nesting, the nested method is used, without the need to define a new category or dedicated id. The nesting of selector and the collective declaration of selector can greatly reduce the declaration of class and id and simplify Css code.
On the Html page, RGB is the three primary colors of red, green, and blue. Each color is composed of different percentages of the three colors, which are divided into 0 ~ 255, for example, rgb (100%, 100%, 100%), rgb (255,255,255), and # FFFFFF all refer to white, where # FFFFFF is a hexadecimal representation, the first two are the red component, the middle is the green component, and the last two are the blue component.
In different browsers, the compatibility of width and height values is poor. If no special declaration is made, in IE7, content + padding is specified) + border refers to the width or height of content in Firefox or google.
The top, right, bottom, and left Css attributes must be used together with the position attribute, it indicates the distance between the boundary of a block and the page border (when the position attribute is set to absolute) or the original position (when the position attribute is set to relative.
If the node that uses getElementById () to obtain the given id has the name attribute of the element with the same name, this element is returned in IE browser. This is a very serious Bug, so we should try to avoid duplication of the id and the name attribute of other elements when building the framework.
<Div> what is different from <span> labels: <div> is a block-level element. The inner element is automatically wrapped, while <span> is just a row element, there is no line feed before and after it.