Display Mode of html tags (Block-level tags, intra-row tags, intra-row block tags) and Label display mode
During the lecture today, we talked about the tag display mode in html, which is roughly divided into block-level labels and intra-Row labels.
Display:block is the display of elements as block-level elements.The block element is characterized by:Always start on a new line;Height, row height and top and bottom margin can be controlled;The width defaults to 100% of its container unless a
I. Block-level elements and row-level elements
To understand the differences between display: inline, block, and inline-block, you must first understand the features of block-level and line-level elements in HTML. In-line elements are also called
Inline-block past and present
Trace | Time:
Once upon a time, the code "display: inline-block; * display: inline; * ZOOM: 1;" was everywhere. Modern browsers now fully support this attribute value. The above code is only for compatibility
Display: inline-block compatible ie6/7 writing, inline-blockie62. What is the function of display: inline-block?
Using the display: inline-block attribute, you can change an element or block element in the row into a block element in the row. Simply
Once upon a while, Display:inline-block has been deep into the streets, everywhere "display:inline-block; *display:inline; *zoom:1; "Such a code. Today, modern browsers have fully supported this property value, and the code above is for
Once upon a while, Display:inline-block has been deep into the streets, everywhere "display:inline-block; *display:inline; *zoom:1; "Such a code. Today, modern browsers have fully supported this property value, and the code above is for
Once upon a while, Display:inline-block has been deep into the streets, everywhere "display:inline-block; *display:inline; *zoom:1; "Such a code. Today, modern browsers have fully supported this property value, and the code above is only for
The difference between block elements and inline elements.
Only one row can set the margin in the width, height, and vertical direction, and the margin and padding in the horizontal direction of padding.
Block Element: Yes, yes, yes
Inline element:
Block-level element Classification (Original: http://kevinpeng.iteye.com/blog/743936)
Block-level elements include structured block elements, terminal block elements, and multi-object block elements.
1. Structured block elements
These
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.