阿神2017-04-17 15:05:32
This...
Come and look at the code; communicate at any time:
HTML:
<p>
<ul>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
</ul>
</p>
CSS:
p{
width: 996px;
height: 120px;
overflow-x:auto;
overflow-y:hidden;
}
ul{
width: 1990px;
}
li{
width: 220px;
height: 300px;
margin: 10px;
float: left;
background: red;
}
ringa_lee2017-04-17 15:05:32
In the same building, put another p on the outer layer, and set the overflow-x of the outer p: auto