您的位置:首页 > Web前端 > CSS

css块级标签、行内标签、行内块级标签

2015-06-17 13:02 579 查看
<html><head lang="en">
<meta charset="UTF-8">
<title></title>
<style>
/*块级标签*/
div{
background-color: red;
width: 200px;
height: 180px;
/*隐藏*/
/*display: none;*/
/*display: inline;*/

display: inline-block;
}

/*p{*/
/*background-color: yellow;*/
/*width: 200px;*/
/*height: 50px;*/
/*}*/

/*行内标签*/
span{
background-color: yellow;
/*让行内标签变成块级标签*/
/*display: block;*/
/*width: 200px;*/
/*height: 50px;*/
}

/* 行内-块级标签*/
input{
width: 200px;
height: 300px;
}
</style>
</head>
<body>
<div>11111111</div>
<div>11111111</div>
<div>11111111</div>

<span>22222222</span>
<span>22222222</span>
<span>22222222</span>

<a href="#">百度一下</a>
<a href="#">百度一下</a>
<a href="#">百度一下</a><br><br><br>
<!--<p>22222</p>-->

<input>
<input>
<input>

</body></html>
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: