当前位置:网站首页 > 技术博客 > 正文

css 栅格



 1 <!DOCTYPE html>
 2 <html>
 3 <head>  4 <meta http-equiv="Content-Type" content="text/html;charset=utf-8"/>
 5 <meta http-equiv="window-target" content="_top">  6 <title>Writing to Same Doc</title>  7 <style type="text/css">  8 * {  9 box-sizing: border-box; 10  } 11     html, body{
12 width: 100%; 13 height: 100%; 14 margin: 0; 15  } 16  .container{ 17 width:100%; 18  } 19  .container:after{ 20  display: table; 21 content:"."; 22  clear:both; 23  } 24 25  .container .cl{ 26 float:left; 27  border: 1px solid red; 28  height: 200px; 29  } 30 31  .main{ 32 width:100%; 33 padding: 0 290px 0 320px; 34 background-color: blue; 35  } 36  .sub{ 37  width: 320px; 38 margin-left:-100%; 39 background-color: white; 40  } 41  .extra{ 42  width: 290px; 43 margin-left:-290px; 44 background-color: yellow; 45  } 46 </style> 47 </head> 48 <body> 49 <div class="container"> 50 <div class="cl main"> 51 <div class="container"> 52 <div class="cl main"></div> 53 <div class="cl sub"></div> 54 <div class="cl extra"></div> 55 </div> 56 </div> 57 <div class="cl sub"></div> 58 <div class="cl extra"></div> 59 </div> 60 61 </body> 62 </html>

版权声明


相关文章:

  • bzero函数使用方法2024-11-18 21:30:02
  • usermod-c2024-11-18 21:30:02
  • spring cloud gateway 服务发现2024-11-18 21:30:02
  • argphe2024-11-18 21:30:02
  • ldap server2024-11-18 21:30:02
  • emule服务器地址列表地址2024-11-18 21:30:02
  • opcache_compile_file2024-11-18 21:30:02
  • 串口助手用什么编的2024-11-18 21:30:02
  • linux框架图2024-11-18 21:30:02
  • 荣耀10pro参数配置详情2024-11-18 21:30:02