HTML Editor
<!DOCTYPE html> <html lang="en-US"> <head> <style> .point::before { content: attr(href); } </style> </head> <body> <h1>CSS content Property</h1> <a href="https://wikimass.com/js">(Learn JavaScript)</a> <button onclick="myFunction()">Click Me</button> <script> var x = document.getElementsByTagName("a")[0]; function myFunction(){ x.className += "point"; } </script> <p><strong>Note</strong>: Click on the button to add css 'content' property.</p> </body> </html>
OUTPUT
×

Save as Private