div田字格
来源:互联网 发布:淘宝卖的红酒是正品吗 编辑:程序博客网 时间:2024/05/12 15:22
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>1</title>
<style>
#first{width: 50%; height: 200px; background: red; float: left}
#second{width: 50%; height: 200px; background: green; float: left;}
#three{width: 50%; height: 200px; background: gray; float: left;}
#third{width: 50%; height: 200px; background: yellow;float: left;}
</style>
</head>
<body>
<div id="first">我是1</div>
<div id="second">我是2</div>
<div id="three">我是3</div>
<div id="third">我是4</div>
</body>
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>1</title>
<style>
#first{width: 50%; height: 200px; background: red; float: left}
#second{width: 50%; height: 200px; background: green; float: left;}
#three{width: 50%; height: 200px; background: gray; float: left;}
#third{width: 50%; height: 200px; background: yellow;float: left;}
</style>
</head>
<body>
<div id="first">我是1</div>
<div id="second">我是2</div>
<div id="three">我是3</div>
<div id="third">我是4</div>
</body>
</html>
first、second、three、third等id不能用1、2、3、4来替代,否则无法显示颜色。
0 0
- div田字格
- div完成田字格布局
- DIV
- DIV
- div
- DIV
- div
- div
- DIV
- div
- div
- div
- div
- div
- div
- div
- div
- <div>
- GUID生产类
- android 捕捉实时logcat日志 并且显示在textview中
- 让我们从机器学习谈起
- ROS系统学习02
- 各种需求的POI标签制作方法大全
- div田字格
- 在Java中的内部类详解,为什么需要内部类?
- Android高效加载大图、多图解决方案,有效避免程序OOM
- 蓝桥杯_生日蜡烛
- 转:IDEA如何打包可运行jar的一个问题
- ioctl()函数详解
- Portal for ArcGIS管理员账号丢失问题解决方法
- 块自适应滤波器
- js简单计时器