bottom-offset-001

Position 'bottom' property defines the offset from the bottom edge of the containing block for absolute positioning

WeasyPrint

This browser

Assertion
The 'bottom' property, for absolute positioning, specifies the offset of the element in relation to the containing block's bottom content edge.

Source

 1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
 2 <html>
 3     <head>
 4         <title>CSS Test: Position 'bottom' property defines the offset from the bottom edge of the containing block for absolute positioning</title>
 5         <link rel="author" title="Microsoft" href="http://www.microsoft.com/">
 6         <link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#propdef-bottom">
 7         <link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#position-props">
 8         <meta name="flags" content="">
 9         <meta name="assert" content="The 'bottom' property, for absolute positioning, specifies the offset of the element in relation to the containing block's bottom content edge.">
10         <style type="text/css">
11             div
12             {
13                 height: 1in;
14                 position: relative;
15                 width: 1in;
16             }
17             #div1
18             {
19                 background: blue;
20             }
21             #div2
22             {
23                 background: white;
24                 height: 0.5in;
25                 position: absolute;
26                 bottom: 0;
27                 width: 0.5in;
28             }
29         </style>
30     </head>
31     <body>
32         <p>Test passes if there is a box below with its bottom-left corner missing.</p>
33         <div>
34             <div id="div1"></div>
35             <div id="div2"></div>
36         </div>
37     </body>
38 </html>