基础小案例01

原创 2019-08-14 18:08:58 175
摘要:<!DOCTYPE html><html lang="en"><head>   <meta charset="UTF-8">   <meta name="viewport" content="width=device-width, in

<!DOCTYPE html>

<html lang="en">

<head>

   <meta charset="UTF-8">

   <meta name="viewport" content="width=device-width, initial-scale=1.0">

   <meta http-equiv="X-UA-Compatible" content="ie=edge">

   <title>浮动</title>

   <style>

     ul li{

         list-style: none;

         width: 100px;

         height: 40px;

         line-height: 40px;

         text-align: center;

         background: #ccc;

         margin: 5px;

         float:left;

     }

     div{

         width: 200px;

         height: 200px;

         background: pink;

         

         

     }

     .clear{

         clear: both;

     }

 

   </style>

</head>

<body>

   <ul>

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

       <li>css</li>

       <li>javascript</li>

       <li>vue</li>

       <li>php</li>

   </ul>

   <div class="clear"></div>

   

   <div>demo1</div>

   <div>demo2</div>

   <div>demo3</div>

   

</body>

</html>


发布手记

热门词条