The format of the Li code:
A). Use CSS to format list characters: ul li{
List-style-type:none
}
B). If you want to change the list character to an image, then: UL li{
List-style-type:none
List-style-image:url (/blog/images/icon.gif);
}
C). To align Left, you can use the following code: ul{
List-style-type:none
margin:0px;
}
D). If you want to add a background color to the list, you can use the following code: ul{
List-style-type:none
margin:0px;
}
ul li{
Background: #CCC;
}
E). If you want to add a mouseover background color effect to the list, you can use the following code: ul{list-style-type:none; margin:0px;}
ul Li a{display:block; width:100% background: #ccc;}
ul Li a:hover{background: #999;} Description: Display:block; this line must be added, so as to block the display!
F). The elements in Li are arranged horizontally, with the key float:left:ul{
List-style-type:none;
width:100%;
}
ul li{
width:80px
Float:left;
}
<LI> parameter setting (commonly used):
For example: <li type= "Square" value= "4" >
Type= "Square"
Only applicable to the non-standard list, set the symbol style, its value has three kinds, such as the following, the default for Type= "disc":
A symbol is a column-entry symbol when type= "disc".
The symbol if "width=10 height=10 border=0> is a column-entry symbol when type=" circle ".
A symbol is a column-entry symbol when type= "square".
Value= "4"
Only applies to the sequential list, the number of that item is set, and the items are incremented by this as the starting number, but the previous items are unaffected and the value can only be 1,2,3. Equal integers, no default values.
<UL> called unordered list tags.
The so-called unordered list is in front of each item plus,, and other symbols, it is also called symbol list.
<UL> parameter setting (commonly used):
For example: <ul type= "Square" >
Type= "Square"
Set the symbol style, its value has three kinds, as follows, the default is Type= "disc":
A symbol is a column-entry symbol when type= "disc".
A symbol is a column-entry symbol when type= "circle".
A symbol is a column-entry symbol when type= "square".
<ul> is the list of items,<li> is a list item, the list of items is listed by the symbol, so you list the default is black dot, there is a <ol> this is a numbered list, with the number of columns, but also with <li> do list items
<li> is a list item, but there are two types of lists, so there must be <ul> or <ol> used to distinguish between unordered tables (small dots) and ordered lists (1,2,3 ...).