I am new to html. My below code when I click on "Lol Me" button the webpage is turning blank? instead of "LOL". What is wrong in the below code.
<html>
<body>
Hi there<br>
<script>
var x = "John said, \"Boy this is good\"";
var y = true;
function write(){
document.write('LOL');
}
function funcy(){
alert('Trozan virus');
}
</script>
<input type="button" value="press me" onclick="funcy()">
<input type="button" value="Lol me" onclick="write()">
</body>
</html>
Regards, Bhanu