<!DOCTYPE html>
<html>
<head>
</head>
<body>
<script>
document.write("Hack The Planet");
document.write("<br><br><br>");
document.write("Mess with the best, die like the rest");
</script>
<script>
alert("I will Jump on Page Load");
</script>
</body>
</html>
This HTML code creates a web page with two JavaScript scripts.
The first script contains three lines of code that use the document.write()
method to write text to the web page. The first line writes "Hack The Planet", and the two <br>
tags create two blank lines of space between the text. The second line writes "Mess with the best, die like the rest".
The second script contains a single line of code that uses the alert()
method to display a pop-up message with the text "I will Jump on Page Load". This pop-up message will appear when the web page finishes loading in the browser.
<script>
alert("First Pop-Up");
alert("Second Pop-Up");
</script>
This JavaScript code will display two popup windows with messages "First Pop-Up" and "Second Pop-Up" respectively. When the script is executed, the first alert box will appear, and after the user closes it, the second alert box will appear. The user needs to click the "OK" button to close each alert box.
No comments:
Post a Comment