Article Introduction: what are the common block-level elements and inline elements in CSS? |
According to the CSS specification, each page element has a display property that determines the type of the element, and each element has a default display property value, such as a DIV element, Its default display property value is "block", which becomes a chunk-level element (Block-level), and the default display property value of a SPAN element is "inline", called an inline element.
Div such block-level elements , will automatically occupy a certain rectangular space, you can set the height, width, internal and external margins and other attributes to adjust the appearance of the rectangle, in contrast, like "span" "a" such as the elements of the line, there is no independent space, It is attached to other block-level elements, so it is not valid to set the attributes such as height, width, inner and outer margins, etc. for the inline elements.
Inline elements (inline elements ) (inline Element)
* A-Anchor point
* ABBR-abbreviation
* Acronym-First word
* B-Bold (not recommended)
* Bdo-bidi Override
* Big-Large font
* BR-line Wrap
* cite-references
* Code-Computer codes (required when quoting source)
* DFN-Define Fields
* EM-emphasis
* Font-fonts set (not recommended)
* I-Italic
* img-Pictures
* Input-Enter box
* KBD-Define keyboard text
* Label-table label
* Q-Short reference
* S-underlined (not recommended)
* Samp-Define sample computer code
* Select-Project selection
* Small-Small font text
* span-commonly used inline container, definition text block
* Strike-underline
* Strong-Bold accent
* Sub-subscript
* SUP-Superscript
* TEXTAREA-multi-line text input box
* TT-Telex text
* U-Underline
* var-Define Variable
Chunk elements (block Element)
* Address-addresses
* BLOCKQUOTE-Block reference
* Center-align block in lift
* Dir-directory list
* Div-Common block-level easy, but also the main tags of css layout
* DL-Definition List
* Fieldset-form control Group
* Form-Interactive form
* H1-Big title
* H2-Subtitle
* H3-3 level Title
* H4-4 level Title
* H5-5 level Title
* H6-6 level Title
* HR-Horizontal divider Line
* Isindex-input Prompt
* menu-List of menus
* Noframes-frames Optional content (for browsers that do not support frame to display this block content
* NoScript-) optional script content (for browsers that do not support script to display this content)
* OL-sorting forms
* P-Paragraph
* Pre-formatted text
* Table-Tables
* ul-Non-sorted list
variable Element
A variable element determines whether the element is a block element or an inline element, depending on the context context.
* Applet-java Applet
* Button-Buttons
* Del-delete text
* Iframe-inline Frame
* INS-Inserted text
* Map-image block (map)
* Object-object Object
* Script-Client scripting