HTML tag Collation

Source: Internet
Author: User

In-line elements: inline element

1. Also known as inline elements, inline elements, etc. the inline elements are generally based on the semantic level (semantic) of the basic elements, can only accommodate the text or its

He inline elements, common inline elements "a";

Common inline elements:

A-anchor point
B-Bold (not recommended)
BR-line break
EM-emphasize
I-Italic
IMG-Images
Input-Enter box
Label-Table Label
Select-Project Selection
Span-a common inline container that defines chunks within a text
Strong-Bold Emphasis
Sub-subscript
SUP-Superscript
TEXTAREA-Multi-line text input box
U-Underline

Block-level elements: block element

1. Each block-level element is a row high by default, adding a block-level element within a row cannot generally add additional elements
(except float float);

2. When two block-level elements are continuously edited, they are displayed in the page wrap. Block-level elements can generally be nested in block-level elements or inline elements;
Common block-level elements:

<1> Div-Common block-level easy, is also the main label of CSS layout
<2> DL-Definition list
<3> H1-H6 Title Tags
<4> HR-Horizontal divider Line
<5> menu-List of menus
<6> ol-Sort Form
<7> P-Paragraph
<8> Table-Table
<9> ul-Non-sorted list

<!doctype html>


<title> New Document </title>
<meta name= "Keywords" content= "" >
<meta name= "Description" content= "" >
<style type= "Text/css" >
body{
margin:0px;
padding:0px;
}

. div1{
height:40px;
line-height:40px;
border:1px solid red;
}

. btn{
height:40px;
width:200px;
line-height:40px;
Text-align:center;
Text-decoration:none;
Background:silver;
border:1px solid red;
Display:block;
}
. btn:hover{
Background:green;
}

ol{
border:1px solid red;
}

ul{
List-style:none;

}
. div2{
width:800px;
height:255px;
Overflow:hidden;
position:relative;
}

ul{
padding:0px;
margin:0px;
List-style:none;
}
UL Li img{
width:800px;
/* Resolve parent container Height increase 4px*/
/* Method One */
/* DISPLAY:INLINE-BLOCK;
vertical-align:middle;*/
/* Method Two */
/*vertical-align:bottom;*/
/* Method Three */
Display:block;
}

. num{
Position:absolute;
bottom:10px;
right:10px;
}
. Num li{
Float:left;
color:red;
width:20px;
height:20px;
line-height:20px;
Text-align:center;
margin-left:10px;
border-radius:10px;
Background:green;
}

Table{width:500px;border-collapse:collapse;}
Table th{border:1px solid silver;background: #CCC;}
Table TR td{border:1px solid silver;}
Table Tbody Tr:hover{background:yellow;}

</style>

<body>

<div>
In-line elements

<div class= "Div1" >
Shanghai <em> billion industry </em> Technology Co., Ltd. <strong><u> company </u></strong><sup>R</sup>
</div>
<a href= "#" class= "BTN" > Submit 11&LT;/A&GT;QQ
<input type= "Radio" name= "Gender" id= "W" ><label for= "W" > Women </label>
<input type= "Radio" name= "Gender" id= "M" ><label for= "M" > Male </label>

</div>



<dl>
<dt> News </dt>
<dd> Domestic </dd>
<dd> International </dd>
<dd> Local </dd>
<dt> Automotive </dt>
<dd> Volkswagen </dd>
<dd> BMW </dd>
<dd> Mercedes </dd>
</dl>

<ol>
<li>AAA</li>
<li>BBB</li>
<li>CCC</li>
</ol>

<ul>
<li>AAA</li>
<li>BBB</li>
<li>CCC</li>
</ul>

<table>
<thead>
<tr>
<th> numbering </th>
<th> User name </th>
<th> Education </th>
<th> Graduate School </th>
</tr>
</thead>
<tbody>
<tr>
<td>1</td>
<td>AAA</td>
<td> Undergraduate </td>
<td>a University </td>
</tr>
<tr>
<td>2</td>
<td>BBB</td>
<td> Graduate </td>
<td>b University </td>
</tr>
<tr>
<td>3</td>
<td>CCC</td>
<td> PhD </td>
<td>c University </td>
</tr>
<tbody>
</table>

<div class= "Div2" >

<ul>
<li></img> </li>
<li></img> </li>
<li></img> </li>
<ul>

<ul class= "num" >
<li>1</li>
<li>2</li>
<li>3</li>
<ul>
</div>
</body>


HTML tag Collation

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.