Syntax
window.open (URL, windowName[, windowFeatures])
Example 1
window.open ("https://wiki.workassis.com","New popup window");
Example 2
<button onclick="openpopup()">Open My Popup</button> <script> function openpopup() { window.open("https://wiki.workassis.com","_blank", "toolbar=0,location=0,directories=0,scrollbars=0,resizable=0,top=500,left=500,width=400,height=400"); } </script>
Window Features
status | The status bar at the bottom of the window. |
toolbar | The standard browser toolbar, with buttons such as Back and Forward. |
location | The Location entry field where you enter the URL. |
menubar | The menu bar of the window |
directories | The standard browser directory buttons, such as What’s New and What’s Cool |
resizable | Allow/Disallow the user to resize the window. |
scrollbars | Enable the scrollbars if the document is bigger than the window |
height | Specifies the height of the window in pixels. (example: height=’350′) |
width | Specifies the width of the window in pixels. |
Advanced popup use plugin like jquery ui