Java Script: How to open a webpage in a new Window

Leave a Comment
This script helps you open a webpage in a browsers  new tab as many  times as you  wish.


Warning: Opening so many windows on your browser may cause the browser not to function normally


<!DOCTYPE html>
<html>
<body>
<p>Click the button to open multiple windows.</p>
<button onclick="myFunction()">Open Windows</button>

<script>
function myFunction() {

    var i = 0;
    while (i <number of times ) {
window.open("http://jahsoncodes.blogspot.com/2014/10/android-recieve-smshow-to-recieve-sms.html");
        i++;
    }

}
</script>
</body>
</html>


0 comments:

Post a Comment