t120401-scope-04-d-test.html (982B)
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> 2 <html xmlns="http://www.w3.org/1999/xhtml"> 3 <head> 4 <title>CSS 2.1 Test Suite: Counter scope and nesting</title> 5 <link rel="help" href="http://www.w3.org/TR/CSS21/generate.html#scope"/> 6 <link rel="help" href="http://www.w3.org/TR/CSS21/generate.html#counters"/> 7 <link rel="help" href="http://www.w3.org/TR/CSS21/generate.html#propdef-content"/> 8 <link rel="help" href="http://www.w3.org/TR/CSS21/syndata.html#counter"/> 9 <style type="text/css"> 10 11 .reset { counter-reset: c; } 12 .rb:before { counter-reset: c; content: "R"; } 13 .use { counter-increment: c; } 14 .use:before { content: counters(c, ".") " "; } 15 16 </style> 17 </head> 18 <body> 19 20 <div><span class="reset"></span><span class="use"></span><span class="reset"></span><span class="use"></span><span class="rb"><span class="use"></span><span class="reset"></span><span class="use"></span></span></div> 21 22 </body> 23 </html>