<html>
<body>
<h1>Change text-decoration with JavaScript</h1>
<p>Click the "Try it" button to underline the H1 element:</p>
<button onclick="myFunction()">Try it</button>
<h1 id="myH1">This is my header</h1>
<script>
function myFunction() {
document.getElementById("myH1").style.textDecoration = "underline";
}
</script>
</body>
<!-- Mirrored from www.w3schools.com/cssref/tryit.asp?filename=trycss_js_text-decoration by HTTrack Website Copier/3.x [XR&CO'2014], Mon, 27 Jan 2020 03:01:24 GMT -->
</html>