descendant-selector-000.xht (945B)
1 <?xml version="1.0" encoding="utf-8"?> 2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> 3 <html xmlns="http://www.w3.org/1999/xhtml"> 4 <head> 5 <title>CSS Test: Selectors: Descendant selectors</title> 6 <link rel="author" title="Gabriele Romanato" href="mailto:gabriele.romanato@gmail.com" /> 7 <link rel="help" href="http://www.w3.org/TR/CSS21/selector.html#descendant-selectors" /> 8 <link rel="match" href="descendant-selector-000-ref.xht"/> 9 <meta name="assert" content="Browsers should apply each rule to the descendant elements"/> 10 <style type="text/css"> 11 body p {border: thin solid orange} 12 div p {border: thin solid blue} 13 h4 span {border: thin solid fuchsia} 14 </style> 15 </head> 16 <body> 17 <p>This paragraph should have a thin orange border.</p> 18 <div><p>This paragraph should have a thin blue border.</p></div> 19 <h4><span>This text should have a thin fuchsia border.</span></h4> 20 </body> 21 </html>