HTML CSS examples for CSS:Selector
CSS attribute-value selector for searching value containing hash # sign
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> div[data-demo=works] { color:Chartreuse; } div[data-demo='#doesnt_works'] { color:yellow; } </style> <!-- w w w .j a v a2 s. c om--> </head> <body> <div data-demo="works"> Lorem ipsum </div> <br> <div data-demo="#doesnt_works"> Lorem ipsum </div> </body> </html>