A{color: #fff; background: #F93; width:100px;height:50px;
/* Width height of inline elements does not work--
<!--Add this conversion to be useful--
<!--convert inline elements to block elements */
Display:block;
}
No added Display:block; Before
width:100px;height:50px; will not work on a
Summary: Both a tag is an inline element, setting its width and height directly will not work, you need to convert inline elements to "blocky elements" to set width and height
Correspondence table
list all inline elements and block elements for easy access laterReference: can set width and Height
Block element
Address-Addresses
BLOCKQUOTE-Block Reference
Center-lifting Alignment block
DIR-List of directories
Div-Common block-level easy, is also the main tag of CSS layout
DL-Definition List
Fieldset-form control Group
Form-Interactive Form
H1-Big title
H2-Subtitle
H3-3 level headings
H4-4 level headings
H5-5 level headings
H6-6 level headings
HR-Horizontal Divider Line
Isindex-input prompt
menu-List of menus
Noframes-frames Optional content (this chunk content is displayed for browsers that do not support frame
NoScript-Optional script content (this content is displayed for browsers that do not support script)
OL-Sort the form
P-Paragraph
Pre-formatted text
Table-Tables
UL-Non-sorted list
Reference: Unable to set width and height before writing Display:block
Inline elements (inline element)
A-anchor point
ABBR-Abbreviation
Acronym-the first word
B-Bold (not recommended)
Bdo-bidi Override
Big-Large font
BR-line break
Cite-citation
Code-Computer codes (required when referencing source)
DFN-Defining fields
EM-emphasize
Font-typeface settings (not recommended)
I-Italic
IMG-Images
Input-Enter box
KBD-Define keyboard text
Label-Table Label
Q-Short Reference
S-Medium dash (not recommended)
Samp-Define sample computer code
Select-Project Selection
Small-Small font text
Span-a common inline container that defines chunks within a text
Strike-Medium Dash
Strong-Bold Emphasis
Sub-subscript
SUP-Superscript
TEXTAREA-Multi-line text input box
TT-Telex text
U-Underline
var-Defining variables
Author: kwoojan: CSS Learning Forum original address: http://www.missyuan.com/thread-438824-1-1.html