In this section, we will be using a simple modal popup created using http://www.w3schools.org/ and then we will write a script to handle that popup. The simple modal pop-up code is given next. We will build the HTML page first and then we will plug the CSS and JavaScript. We have kept the CSS and JavaScript external for the sake of simplicity:
<html>
<head>
<link rel="stylesheet" type="text/css" href="GetModal.css">
</head>
<body onload="test()">
<!-- Trigger/Open The Modal -->
<button id="myBtn">Open Modal</button>
<!-- The Modal -->
<div id="myModal" class="modal">
<!-- Modal content -->
<frame name="MainWindow">
<div class="modal-content">...