案例:CSS3 案例     状态:可编辑再运行    进入竖版
 运行结果 
x
 
1
<html>
2
<head>
3
<style type="text/css">
4
img 
5
{
6
float:right;
7
border:1px dotted black;
8
margin:0px 0px 15px 20px;
9
}
10
</style>
11
</head>
12
13
<body>
14
<p>在下面的段落中,图像会浮动到右侧,并且添加了点状的边框。我们还为图像添加了边距,这样就可以把文本推离图像:上和右外边距是 0px,下外边距是 15px,而图像左侧的外边距是 20px。</p>
15
<p>
16
<img src="/img/eg_cute.gif" />
17
This is some text. This is some text. This is some text.
18
This is some text. This is some text. This is some text.
19
This is some text. This is some text. This is some text.
20
This is some text. This is some text. This is some text.
21
This is some text. This is some text. This is some text.
22
This is some text. This is some text. This is some text.
23
This is some text. This is some text. This is some text.
24
This is some text. This is some text. This is some text.
25
This is some text. This is some text. This is some text.
26
This is some text. This is some text. This is some text.
27
</p>
28
</body>
29
30
</html>
31