<!DOCTYPE html>
<html lang="en-US">
<body>
<h1>CSS font-style Property</h1>
<p>font-style of this paragraph is italic.</p>
<button onclick="myFunction()">Click Me</button>
<script>
var x = document.getElementsByTagName("p")[0];
function myFunction(){
x.style.fontStyle = "italic";
}
</script>
<p><strong>Note</strong>: Click on the button to change 'font-style' from normal to italic.</p> </body>
</html>