19年1月18号CSS浮动float

原创 2019-01-18 16:13:46 300
摘要:<html><head>    <title>浮动</title>    <style> *{margin:0;padding:0;} ul li{    list-style:none;    width:80px;   &nb

<html>

<head>

    <title>浮动</title>

    <style>

*{margin:0;padding:0;}

ul li{

   list-style:none;

   width:80px;

   height:40px;

   background-color:#ccc;

   text-align:center;

   line-height:40px;

   margin:0px 1px;

   float:left;

}


ul li:hover{

   background-color:red;

   color:blue;

}

    </style>

</head>

<body>

    <ul>

<li class="item">html</li>

<li class="item">Js</li>

<li class="item">PHP</li>

<li class="item">MySQL</li>

<li class="item">jQuery</li>

    </ul>

</body>

</html>


批改老师:灭绝师太批改时间:2019-01-18 17:18:13
老师总结:前端浮动是魔鬼啊,你这个测试少了,没有体现到浮动的难点

发布手记

热门词条