我自仰头向天笑,笑完我就去睡觉,哈哈哈哈……

清除浮动

 来自:http://www.iyunlu.com/view/css-xhtml/55.html

复制代码
 1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
 2 <html xmlns="http://www.w3.org/1999/xhtml">
 3 <head>
 4 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
 5 <title> CSS - Table</title>
 6 <style>
 7 html ,body{
 8 top:0;
 9 margin:0;
10 padding:0;
11 }
12 .body{
13 position:fixed;
14 width:100%;
15 border:0px solid #111;
16 }
17 
18 
19 .clearfix1{
20     border:1px solid #111;
21     padding:10px;
22 
23 }
24 
25 .clearfix:after {content:"."; display:block; height:0; visibility:hidden; clear:both; }
26 .clearfix { *zoom:1; }
27 
28 
29 .content{
30     float:left;
31     width:200px;
32     height:200px;
33     border:1px solid #111;
34 }
35 </style>
36 </head>
37 <body>
38 
39 <div class="body">
40 
41     <div class="clearfix1 clearfix" >
42         <div class="content">
43             1
44         </div>
45         <div class="content">
46             2
47         </div>
48         <div class="content">
49             3
50         </div>
51         <div class="content">
52             4
53         </div>
54     </div>
55 
56 </div>
57 
58 </body>
59 </html>
复制代码
posted @   轻轻的烟雾  阅读(160)  评论(0编辑  收藏  举报
编辑推荐:
· 从 HTTP 原因短语缺失研究 HTTP/2 和 HTTP/3 的设计差异
· AI与.NET技术实操系列:向量存储与相似性搜索在 .NET 中的实现
· 基于Microsoft.Extensions.AI核心库实现RAG应用
· Linux系列:如何用heaptrack跟踪.NET程序的非托管内存泄露
· 开发者必知的日志记录最佳实践
阅读排行:
· TypeScript + Deepseek 打造卜卦网站:技术与玄学的结合
· Manus的开源复刻OpenManus初探
· 写一个简单的SQL生成工具
· AI 智能体引爆开源社区「GitHub 热点速览」
· C#/.NET/.NET Core技术前沿周刊 | 第 29 期(2025年3.1-3.9)
点击右上角即可分享
微信分享提示