string-set-012.html (685B)
1 <!DOCTYPE html> 2 <html> 3 <head> 4 <meta charset="utf-8"> 5 <title>CSS Test: GCPM string-set to attribute value</title> 6 <link rel="author" title="Dave Cramer" href="mailto:dauwhe@gmail.com"> 7 <link rel="help" href="http://www.w3.org/TR/css-gcpm-3/#setting-named-strings-the-string-set-pro"> 8 <meta name="flags" content="paged"> 9 <meta name="assert" content="Test checks that a string can be set to the value of an attribute "> 10 11 <style> 12 @page { 13 @top-center { 14 content: string(header); 15 } 16 } 17 18 h1 { 19 string-set: header attr(title); 20 } 21 22 23 </style> 24 </head> 25 <body> 26 <h1 title="Hello, World">Chapter Title</h1> 27 <p>Test passes if running head text reads “Hello, World”. 28 29 30 31 32 </body> 33 </html>