1.标准文档流
是指元素在页面上的排列规则:行元素从左到右,块元素从上到下
2.浮动
float(left,right,none)
3.图文混排
文字环绕图片
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<style>
img{
width: 100px;
height: 100px;
/* 设置浮动属性 */
float: left;
/* 不环绕 */
/* float: none; */
/* 依旧支持外边距 */
margin: 20px;
padding: 20px;
}
</style>
</head>
<body>
<img src="../1.gif">
<p>
不必几和死的