OLD | NEW |
| (Empty) |
1 <!DOCTYPE html> | |
2 <title>CSS Reference</title> | |
3 <link rel="author" title="Adobe" href="http://html.adobe.com/"> | |
4 <link rel="author" title="Bem Jones-Bey" href="mailto:bjonesbe@adobe.com"> | |
5 <link rel="help" href="http://dev.w3.org/csswg/css-shapes-1/#relation-to-box-mod
el-and-float-behavior"> | |
6 <meta name="flags" content="ahem"> | |
7 <head> | |
8 <style> | |
9 .container { | |
10 font: 20px/1 Ahem, sans-serif; | |
11 line-height: 20px; | |
12 width: 100px; | |
13 height: 40px; | |
14 border: 1px solid black; | |
15 color: green; | |
16 display: inline-block; | |
17 background-color: red; | |
18 } | |
19 | |
20 #float-left { | |
21 float: left; | |
22 width: 100px; | |
23 height: 20px; | |
24 background-color: green; | |
25 } | |
26 | |
27 #float-right { | |
28 float: right; | |
29 width: 100px; | |
30 height: 20px; | |
31 background-color: green; | |
32 } | |
33 </style> | |
34 | |
35 <body> | |
36 <p>This should display two green rectangles. You should not see any red.</p> | |
37 <div class="container"> | |
38 XXXXX | |
39 <div id="float-left"> | |
40 </div> | |
41 </div> | |
42 <div class="container"> | |
43 XXXXX | |
44 <div id="float-right"> | |
45 </div> | |
46 </div> | |
47 </body> | |
OLD | NEW |