Make a Pop-up Window

In this tutorial, we will be using the onclick=attribute in a hyperlink to create a new window that will pop up when the link is clicked.

You should have a page that you want to be popped up in a new window already, if not, create one. If you want your pop-up window to be small, make sure that the layout or contents of your pop up window page does not exceed the size you’re going for. For example, if you wish to create an 500×500 window as we will be doing in this tutorial, your header should not go over 500 pixels or it’ll stretch out.

Now on the page that you want your link to be, include the onclick attribute to your “a href” tag like so:
<a href="http://www.yoursitehere.com/yourpage.html"
onclick="window.open('http://www.yoursitehere.com/yourpage.html','popup','width=500,height=500,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0'); return false">My Page Link Name</a>
This will be the link to your pop-up page. Replace the links and link name with your own. Once the link that you have created is clicked, a new window will pop-up with the page that you’ve created.

There are variables in the code that can be modified to suit your liking, such as the width and height of the window that will pop up, whether you want scroll bars to be visible or not, etc.