Web page Crafting tips: The applicability of XHTML tags and CSS attributes

Source: Internet
Author: User
Tags min

Article Introduction: XHTML tag elements can be divided into: replacement elements and irreplaceable elements.

xhtml tag elements can be divided into: substitution elements and irreplaceable elements
A substitution element refers
to the element that controls the display of content by combining label and label attributes.
For Example: Label must be together with SRC attribute to define picture display;
table cell element label must be matched with type selection types;
non-replacement elements refer to: elements that directly display the content of the Web page (most of the page elements belong to this category)
XHTML tag elements can also be divided into: block-level elements and inline elements
block-level elements: content does not wrap (you can set width and height)
Inline elements: Content Wrapping (no width and height can be set) * Replace elements except inline elements (you can set width and height)
the applicability of CSS properties is to determine which properties are available and which properties are unavailable through the different elements .
CSS Property Applicability Rollup:
1) only use block elements apply: text-align;text-indent;clear;
2 Only the positioning element is applicable: Top/right/bottom/left;z-index;
3) Only the list element is applicable (Display:iist-item): list-style-type;list-style-image;list-style-position;
4 only: Before and: After application: content;
5 only inline elements and table cells Apply: Vartical-align;
********************************************
Applicability of individual properties:
1) Applicability of Width/height/min-width/min-height/max-width/max-width:
all elements, in addition to the inline elements of a replacement element, table rows and table row groups
2) margin/padding applicability:
all elements except table rows; table row group; table column; table column Group; table header Group; table Footer Group;
3) Overflow applicability:
block-level elements and substitution elements
4) Clip applicability:
Absolute positioning elements only (including absolute and fixed positioning)
Only a continuous summary can be more in-depth understanding of knowledge and find their own shortcomings.


Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.