highlight-text-across-elements-ref.html (625B)
1 <!DOCTYPE html> 2 <html> 3 <head> 4 <style> 5 :root { 6 font-family: monospace; 7 } 8 #style1 { 9 background-color: yellow; 10 color:green; 11 } 12 #style2 { 13 background-color: blue; 14 color:red; 15 } 16 #style3 { 17 background-color: purple; 18 color:pink; 19 } 20 </style> 21 </head> 22 <body> 23 One <span id="style1">two</span> th<span id="style2">ree 24 four</span> five <span id="style2">six 25 seven</span> eigh<span id="style3">t nine 26 ten eleven twelve 27 thirteen fou</span>rteen fifteen 28 </body> 29 </html>