HTML Editor
<!DOCTYPE html> <html lang="en-US"> <body> <h1>CSS font-size Property</h1> <button onclick="myFunction()">Click Me</button> <script> var x = document.getElementsByTagName("h1")[0]; function myFunction(){ x.style.fontSize = "40px"; } </script> <p><strong>Note</strong>: click on the button to change the font-size.</p> </body> </html>
OUTPUT
×

Save as Private