class 1 模板&盒子模型

发布时间:2020-07-22 06:23:55 作者:paopao0
来源:网络 阅读:254

基础模板

<!DOCTYPE html>

<html>

<head>

<meta charset="utf-8">

<title>随意</title>

</head>

<body> 


</body>

</html>


盒子模型

<!DOCTYPE html>

<html>

<head>

<meta charset="utf-8">

<title>随意</title>

<style>

   body{

    margin:10px;

    padding:10px;

       }

   .uni{(uni—相同部分 以便减少代码)

    width:200px;

    height:200px;

    float:left;(浮动:left左/right右)

       }

   #first{(#是id)

     width:500px;

     height:500px;

     background:white;

     margin:0 auto;

         }

   #second{

      background:red;

      margin-right:10px;

      margin-bottom:10px;

          }

   #third{

     background:green;

     margin-bottom:10px;

         }

   #fourth{

     background:black;

     margin-right:10px;

          } 

   #fifth{

     background:blue;

         } 

</style>    

</head>

<body> 

<div id="first">

  <div id="second" class="uni">(class定义为任意字母)

  </div>

  <div id="third" class="uni">

  </div>

  <div id="fourth" class="uni">

  </div>

  <div id="fifth" class="uni">

  </div>

</div>

</body>

</html>


推荐阅读:
  1. java中abstract class和interface有什么区别
  2. django如何为Form生成的label标签添加class

免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。

盒子模型 la clas

上一篇:经典案例:企业H3C组网实例

下一篇:移动app商城UI模板(仿淘宝)

相关阅读

您好,登录后才能下订单哦!

密码登录
登录注册
其他方式登录
点击 登录注册 即表示同意《亿速云用户服务条款》