css3-background-size-001.html (1086B)
1 <!DOCTYPE html> 2 <html lang="en"> 3 <head> 4 <meta charset="utf-8" /> 5 <title>CSS Backgrounds Test:background size property</title> 6 <link rel="author" title="yanshasha" href="mailto:yanshasha133@gmail.com" /> 7 <link rel="reviewer" title="Dayang Shen" href="mailto:shendayang@baidu.com" /><!-- 2013-08-26 --> 8 <link rel="help" href="http://www.w3.org/TR/css3-background/#the-background-size" /> 9 <link rel="match" href="reference/css3-background-size-001-ref.html" /> 10 <style type="text/css"> 11 div { 12 width: 150px; 13 height: 150px; 14 background-image: url(support/green-150-150.png); 15 background-repeat: no-repeat; 16 } 17 #div1 { 18 background-size: 30%; 19 } 20 #div2 { 21 background-size: 60%; 22 } 23 </style> 24 </head> 25 <body> 26 <p> 27 The test passes if the following three green squares have different size. 28 </p> 29 <div id="div1"></div> 30 <div id="div2"></div> 31 <div id="div3"></div> 32 </body> 33 </html>